ibus-unikey is now in the AUR
Posted on 9:48 PM under arch linux 2 comments
I've uploaded a PKGBUILD for ibus-unikey to the ArchLinux AUR. You can install it with yaourt like this:
Then add the following to your .bash_profile
PS: Ok, there is no spyware/malware/rootkit in this binary package! If you don't trust me, don't use this method and build the package yourself (this is the way I recommend)
yaourt -S ibus-unikeyIf you don't want to build from the source, you have to install all the dependencies first:
pacman -Sy gcc gconf gtk2And then download and install the binary package
Then add the following to your .bash_profile
export XMODIFIERS=@im=ibus
export GTK_IM_MODULE=ibus
export QT_IM_MODULE=ibus
PS: Ok, there is no spyware/malware/rootkit in this binary package! If you don't trust me, don't use this method and build the package yourself (this is the way I recommend)
I've just joined a project as a freelancer to customize a commercial e-commerce solution (so let called it EP). OOTB, the email sending of EP does not support authentication, which is a weird thing for such a cool product like that. Actually, EP does declare an JNDI mail session in the context, but in the code they don't use it. With the source code of EP in hand, things get much easier. First, we declare a JNDI resource in our application context (either in your context file in the conf/Catalina/localhost/ or in your context.xml under META-INF inside your war):
Hope that may help!
<context>And put those in your web.xml file:
<Resource name="mail/Session" auth="Container"
type="javax.mail.Session"
username="my.smtp.user"
password="my-secret"
mail.debug="false"
mail.transport.protocol="smtp"
mail.smtp.host= "xxx.xxx.xxx.xxx"
mail.smtp.auth= "true"
mail.smtp.port= "25"
mail.smtp.starttls.enable="true"
description="Global E-Mail Resource"
/>
</context>
<resource-ref>And now, in your Java code, you will use this email session like this:
<description>Email Session</description>
<res-ref-name>mail/Session</res-ref-name>
<res-type>javax.mail.Session</res-type>
<res-auth>Container</res-auth>
</resource-ref>
Context initContext = new InitialContext();If you get a java.lang.ClassCastException, don't worry, this is a known issue. It's because you have multiple Java Mail jar file and Java Activation Framework jar file in your CLASSPATH!
Context context = (Context) initContext.lookup("java:comp/env");
Session mailSession = (Session) context.lookup("mail/Session");
//Your code to send the email goes here
Hope that may help!