Run Redmine as local service at startup on Linux

Open a console on the linux machine where your Redmine installation is and create the init script by typing: touch /etc/init.d/redmine.sh If you haven’t write permissions on “/etc/init.d/” dir, please switch to root user, typing: su – and redo the previous commands . Otherwise (for Ubuntu users) use “sudo”: sudo […]


Set Redmine as Windows service

To setup and run your Redmine installation as a Windows service, open a command prompt and type: cd C:\Ruby23\bin gem install win32-service Under you redmine installation dir (e.g. “C:\My_Redmine”) create a text file named “service.rb” with the following code (in this example our ip address is 192.168.10.1 and the port […]


Install Redmine on Windows

Be careful, these commands are valid for MySQL environment. Other DBMS (PostgreSQL, SQLServer) could have quite different syntax. See redmine documents for details. We assume that you have already installed a MySQL environment that is up and running. Get and configure redmine application Get Redmine source code from here, and put […]


Get rows that don’t exist in another SQL table

There are three ways to select all records from one table that do not exist in another table: SELECT field1 FROM table1 WHERE field1 NOT IN (SELECT field1 FROM table2) SELECT field1 FROM table1 WHERE NOT EXISTS (SELECT * FROM table2 WHERE table1.field1 = table2.field1) SELECT field1 FROM table1 LEFT […]


Add proxy exceptions from command-line on Ubuntu GNOME

To change proxy settings from cli in GNOME-based Ubuntu desktop, it’s possible to use gsettings commands. To see the current proxy exceptions, type the following command on linux console gsettings get org.gnome.system.proxy ignore-hosts The option ignore-hosts means the proxy exceptions. In this case the default output should be something like [‘localhost’, ‘127.0.0.0/8’, […]


301 redirection with trailing slashes on WordPress

With WordPress redirection plugins you can easily set page 301 redirects. But sometimes redirection not involve “trailing slashes” (trailing slash means the slash at the end of an URL). For example, if you want to jump from get-in-touch page to conctact-us page,  a simple redirection means that www.mysite.com/get-in-touch and www.mysite.com/get-in-touch/ could be not considered as […]


Create a Git Server

The best way to collaborate with someone is to create an intermediate repository to both send and download data. We will refer to this repository as a “Git server”. Create a Git server is quite simple. To initialize any Git server, you must export an existing repository to a new […]


Set username/email on Git

To set Git global username and password on your system do the following: Set username (e.g. Abby Normal) git config –global user.name “ABBY NORMAL” Set email (e.g. abby.normal@foobar.com) git config –global user.email “abby.normal@foobar.com”   To configure repository specific values, change directory to the root of the repository and do the following: […]


Fix a detached head on Git

Open a terminal and, under your git directory, create a new temporary branch (e.g. temp): git branch temp Switch on the new branch typing: git checkout temp Point the master to the new branch (force it with option -f): git branch -f master temp Switch back on the master and […]


Add a Magento Admin User using SQL

Sometimes we aren’t able to access to our Magento admin panel. No fear! You can create a new admin user directly via DB. Let’s suppose to create a user with name ‘AdminUser’, surname ‘Foobar’, email ‘adminuser@test.com’, username ‘myname’ and password ‘mypassword’. Open a command line shell, connect to your MySQL DBMS and […]