Set up jdk, apache tomcat, and hsqldb
==============================
apt-get install sun-java6-jdk
apt-get install tomcat5.5 tomcat5.5-wepapps tomcat5.5-admin
apt-get install hsqldb-server
Set up jogre
=========
wget http://voxel.dl.sourceforge.net/sourceforge/jogre/jogre_beta_0.3_bin.zip
cd /opt
unzip ~/jogre_beta_0.3.bin.zip
adduser jogre
chown -R jogre:jogre jogre
su jogre
cd
echo "export CLASSPATH=$CLASSPATH:/usr/share/java/hsqldb.jar:." >> .profile
source .profile
java org.hsqldb.Server &
cd /opt/jogre/server
chmod a+x *.sh
Configuration
==========
./server.sh &
#I prefer the gui; it's easier to just change the db settings with this tool
./administrator.sh &
#Login with admin, admin
#Change the database from xml to hsqldb
#The path to the db is jdbc:hsqldb:hsql://localhost/jogre_hsqldb
#restart the jogre server
killall server.sh
./server.sh &
#With apache tomcat admin (http://localhost:8180/admin), add jogreweb.war
Showing posts with label tools. Show all posts
Showing posts with label tools. Show all posts
Wednesday, June 10, 2009
Saturday, June 6, 2009
SVN commands
Creating a new repository for SVN
svnadmin create /path/to/svn/newrepository
Importing
svn --username user import http://svnsite.com/path/to/svn/newrepository -m "initial import"
#note about importing
#create a local folder called newrepository and put whatever code you want to import into newrepository
#run svn from newrepository
Permission denied when importing
# Do this on the server's svn directory
sudo chown -R www-data:www-data svn
svnadmin create /path/to/svn/newrepository
Importing
svn --username user import http://svnsite.com/path/to/svn/newrepository -m "initial import"
#note about importing
#create a local folder called newrepository and put whatever code you want to import into newrepository
#run svn from newrepository
Permission denied when importing
# Do this on the server's svn directory
sudo chown -R www-data:www-data svn
Flash tricks - global vars, functions, timers
Creating global var-
_global.myvar
Creating a timer-
var starttime = getTimer();
var atime=0;
while (atime < _global.timestop+starttime){
atime = getTimer();
if (_global.conn_state == true){
break;
}
}
Creating a function-
function populateJoin(){
gamelist.data = _global.currentmsg.split(_global.SEP);
gamelist.labels = _global.currentmsg.split(_global.SEP);
}
_global.myvar
Creating a timer-
var starttime = getTimer();
var atime=0;
while (atime < _global.timestop+starttime){
atime = getTimer();
if (_global.conn_state == true){
break;
}
}
Creating a function-
function populateJoin(){
gamelist.data = _global.currentmsg.split(_global.SEP);
gamelist.labels = _global.currentmsg.split(_global.SEP);
}
Photoshop Tricks - alpha channels and actions
Creating an alpha channel (ps cs2)-
magic lasso outside of the object
inverse select
go to channels
click save selection as channel
Now you can save with the alpha channel
Creating an action (ps cs2)-
Click the actions tab
Click new actions and click record
Do what you want to record and press stop
Automatically start action (ps cs2)-
go to file ->scripts
click scripts events manager
check the enable events to run scripts/actions
associate your action with an event
magic lasso outside of the object
inverse select
go to channels
click save selection as channel
Now you can save with the alpha channel
Creating an action (ps cs2)-
Click the actions tab
Click new actions and click record
Do what you want to record and press stop
Automatically start action (ps cs2)-
go to file ->scripts
click scripts events manager
check the enable events to run scripts/actions
associate your action with an event
Java Me Notes
Links
Main site
http://java.sun.com/javame/index.jsp
Download
http://java.sun.com/products/sjwtoolkit/download.html
Eclipse plugin
http://download.eclipse.org/dsdp/mtj/updates/0.9/stable/
Need to use eclipse to export jad and jar for the project (which is in deploy)
Conventions
startApp() --> like main
import javax.microedition.lcdui.*; //required to use display
Display // interface with phone screen
Form //set up the screen then attach it to display
myform.append("some text"); //a label
Main site
http://java.sun.com/javame/index.jsp
Download
http://java.sun.com/products/sjwtoolkit/download.html
Eclipse plugin
http://download.eclipse.org/dsdp/mtj/updates/0.9/stable/
Need to use eclipse to export jad and jar for the project (which is in deploy)
Conventions
startApp() --> like main
import javax.microedition.lcdui.*; //required to use display
Display // interface with phone screen
Form //set up the screen then attach it to display
myform.append("some text"); //a label
Friday, June 5, 2009
See list of mac file servers on network
This is quick way to get a list of appletalk machines on your network when you only have access to the terminal.
atlookup
atlookup
Wednesday, June 3, 2009
Force a live update from command line
This will perform a silent live update of Symantec Antivirus 10.2
"c:\Program Files\Symantec AntiVirus\VPDN_LU.exe" /fUpdate /s
"c:\Program Files\Symantec AntiVirus\VPDN_LU.exe" /fUpdate /s
Adding a printer with vbscript from a network share
rem Add the connection
cscript prnmngr.vbs -ac -p \\server\printer_share
rem Set it as a default
cscript prnmngr.vbs -t -p "\\server\printer name"
rem If you don't know the name
cscript prnmngr.vbs -l
cscript prnmngr.vbs -ac -p \\server\printer_share
rem Set it as a default
cscript prnmngr.vbs -t -p "\\server\printer name"
rem If you don't know the name
cscript prnmngr.vbs -l
Adding an extension to a bunch of files
#I made a bunch of text files for Windows, but XP cannot open them without an extension
#This was a quick fix
find . -type f -exec mv {} {}.txt \;
#This was a quick fix
find . -type f -exec mv {} {}.txt \;
Tuesday, June 2, 2009
Debian package manager
#useful Debian/Ubuntu package commands
apt-get install package
apt-get remove package
apt-get update #good for updating your database after editing sources.list
apt-cache search search_string
dpkg --list
dpkg --install program.deb
dpkg --remove program
#Sometimes you have to add this to /etc/apt/sources.list
# etch is a version of Debian, replace with your version
deb http://security.debian.org/ etch/updates main contrib
deb-src http://security.debian.org/ etch/updates main contrib
deb http://ftp.debian.org/debian/ etch main
deb-src http://ftp.debian.org/debian/ etch main
#these are good for install outside packages like java
deb http://ftp.debian.org/debian/ unstable non-free
deb-src http://ftp.debian.org/debian/ unstable non-free
apt-get install package
apt-get remove package
apt-get update #good for updating your database after editing sources.list
apt-cache search search_string
dpkg --list
dpkg --install program.deb
dpkg --remove program
#Sometimes you have to add this to /etc/apt/sources.list
# etch is a version of Debian, replace with your version
deb http://security.debian.org/ etch/updates main contrib
deb-src http://security.debian.org/ etch/updates main contrib
deb http://ftp.debian.org/debian/ etch main
deb-src http://ftp.debian.org/debian/ etch main
#these are good for install outside packages like java
deb http://ftp.debian.org/debian/ unstable non-free
deb-src http://ftp.debian.org/debian/ unstable non-free
net time commands
net time (time from domain server)
net time /querysntp
net time /set \\another_pc
net time /setsntp:time.apple.com
net time /querysntp
net time /set \\another_pc
net time /setsntp:time.apple.com
Subscribe to:
Posts (Atom)