SVN post-commit hook for Windows and Linux

For demonstration purposes I have rewritten a post-commit hook (which was originally developed for Linux) for Windows.

post-commit (Linux version)

#!/bin/sh
# POST-COMMIT HOOK
# The post-commit hook is invoked after a commit.
#
#   [1] REPOS-PATH   (the path to this repository)
#   [2] REV          (the number of the revision just committed)
#
REPOS="$1"
REV="$2"
 
echo $REPOS $REV >> /tmp/test.txt

post-commit.bat (Windows version)

@echo off
:: POST-COMMIT HOOK
:: The post-commit hook is invoked after a commit.
::
::  [1] REPOS-PATH   (the path to this repository)
::  [2] REV          (the number of the revision just committed)
::
@echo off  
 
set REPOS=%1
set REV=%2   
 
echo %REPOS% %REV% > C:/Temp/test.txt

How to install node.js on a Debian server

How to install node.js (latest version)

apt-get install g++ curl libssl-dev apache2-utils git-core -y
cd /etc
git clone git://github.com/joyent/node
cd /etc/node
./configure
make
sudo make install

How to install node.js (stable version)

apt-get install g++ curl libssl-dev apache2-utils git-core -y
cd /tmp
wget http://nodejs.org/dist/v0.6.11/node-v0.6.11.tar.gz
tar xvf node-v0.6.11.tar.gz
mv /tmp/node-v0.6.11 /etc
cd /etc/node-v0.6.11
./configure
make
sudo make install
rm /tmp/node-v0.6.11.tar.gz

You can check the installed version with node --version.

node.js package manager

If you want to use a package manager for node.js (like npm), then you can get it with:

curl http://npmjs.org/install.sh | sh

To use the package manager, just go into your node.js webproject and execute something like:

npm install websocket.io

This command will load the desired dependencies (like websocket.io) into a directory called „node_modules“ within your project’s folder.

Uninstalling node.js

To uninstall node.js, just go to the folder where you installed node.js (e.g. /tmp/node-v0.6.11) and use the following command:

make uninstall

How to install Java 7 on Debian

Here is a tutorial on how to install the latest Java 7 JDK and JRE on a Debian Linux system:

1
2
3
4
5
6
7
8
9
10
11
12
13
apt-get update && apt-get upgrade -y
sudo apt-get install sun-java6-jdk -y
mkdir /tmp/downloads && cd /tmp/downloads 
wget http://download.oracle.com/otn-pub/java/jdk/7u2-b13/jdk-7u2-linux-i586.tar.gz
tar -xvf jdk-7u2-linux-i586.tar.gz
mv /tmp/downloads/jdk1.7.0_02 /usr/lib/jvm
mv /usr/lib/jvm/jdk1.7.0_02 /usr/lib/jvm/java-7-oracle
sudo update-alternatives --install "/usr/bin/java" "java" "/usr/lib/jvm/java-7-oracle/bin/java" 1
sudo update-alternatives --install "/usr/bin/javac" "javac" "/usr/lib/jvm/java-7-oracle/bin/javac" 1
sudo update-alternatives --install "/usr/bin/javaws" "javaws" "/usr/lib/jvm/java-7-oracle/bin/javaws" 1
sudo update-alternatives --config java
java -version
rm -r /tmp/downloads

Tetris Battle – We are having difficulties logging into Facebook. Please try again later.

If you have any problems with the Facebook game Tetris Battle, then you should see if third-party cookies are enabled in your browser. Often they are not. Therefore, the error message „We are having difficulties logging into Facebook. Please try again later.“ appears in many browsers.

To fix this problem, you can do the following:

Thanks to the Tetris Battle Online Customer Support for this information!

RCON (Remote Console) benutzen

Mit der Remote Console (kurz RCON) können Counter-Strike Server außerhalb des Server-Terminals administriert werden. Es ist damit sogar möglich, den Server innerhalb des Spiels zu bedienen. Leider ist die RCON im Spiel sehr versteckt, weshalb ich euch in diesem Beitrag erkläre, wie ihr die Konsole für RCON aktivieren und verwenden könnt.
RCON (Remote Console) benutzen weiterlesen

Counter-Strike: Source Server aufsetzen unter Linux

Wer schon immer mal einen eigenen Counter-Strike: Source Server aufsetzen wollte, hat jetzt die Möglichkeit dazu. Ich habe eine Anleitung für die Einrichtung eines CSS-Servers geschrieben und auf meinem Virtual Server (mit Debian-Betriebssystem) erfolgreich ausprobiert. Dieses Tutorial möchte ich euch natürlich nicht vorenthalten.
Counter-Strike: Source Server aufsetzen unter Linux weiterlesen