Introduction

For most people when they first come to Unix (or Unix-based, Unix-liked OS such as MacOS, Linux,…), usually one of the most confusing thing is the user account (home directory, permission,…). This article will provide an overview of some basic features about user account as well as some useful tips to take advantages of these features in Unix system.

Home directory

What is Home directory

First, let me explain what is Home directory in Unix system. In multi-user Unix systems, each user has it own home directory. It’s the folder which that user has the full read-write access. That user’s files is protected from other users in the same system, except for root. It’s also the place for the system to store that particular user’s preferences, habits and profile for applications. This mean the system as well as the applications can behave differently, apply different settings for each user thank to the config files stored in each user’s home directory.

Windows users have not been familiar with the term Home directory until those recent version of Windows. In the past, the home folder for each Windows user is the My Document folder. In Windows 7, each user have there own home folder user C:\Users. However, the design of home folder on Windows is not as good as one on Unix system.

Read more

Magit is one of the best tool for working with git. However, it’s a package ship with Emacs, not a standalone application, which prevents many non-emacs people from using it because they don’t want to deal with all the configuartion in the init file. Luckily, there is a python script called magit-wrapper https://github.com/ubolonton/magit-wrapper, which can help that kind of people and act as a gateway drug to Emacs. Moreover, Emacs users can use it for working with files on a remote server to avoid having to install all the Emacs GUI and the full user init .emacs.d folder.

Screenshot

Read more

Warning: this solution is no longer available on newer version of OSX. I tested it on Mac OS 10.6 long time ago. Please don’t ask me about any problem about it because I use only one Google Drive account now :)

Introduction

For several months, I have been using only one Google account for storing and syncing my files between computers. It is really a great tool since it’s integrated deeply with many Google services (which I use everyday). However, the storage is a problem for most cloud drive service. Before that, it offers only 5GB for free and now 15GB, still not enough for me even when I use the email that my university provided (with the capacity up to 30GB for free). Today, while I was browsing my Google Drive, I suddenly thought that it would be very nice if I can combine all my Google accounts’ storage capacity because I have 4 daily used Google accounts. The problem is that Google has restricted the Google Drive desktop app to be able to run one single instance with one profile at one time. That led to the inconvience when I have to disconnect and then re-login into another account and select the right folder for it everytime I want to change account.

Finally, after a whole hour Google searching for a solution to use multiple GDrive accounts without any results, I decided to do it on my own. Luckily, after spending all of my weekend afternoon researching shell commands, I have successfully come up with a nearly perfect solution for using multiple Google Drive accounts on my Mac.

Read more

Introduction

Nowaday, with the development of technology, you probably own more then one technological devices. You can have a Windows PC for playing games at home, a MacOS computer for working purpose and a Windows Phone one for on-the-go entertainment. One popular problem for people who have than one devices is managing, organizing their files, especially music library (other types will be discussed in other articles).

Luckily, if you are using Android devices along with your computer, there is a solution from Google called Google Play Music. It helps you centralize your music library on the cloud for easy management. It also provides the ability to organize the music library by artist, album, playlist,… You can then listen to your collection online from any computer with an Internet connection and ofline on Android with the help of Google Play Music app.

Requirements

  • At least one computer (Windows, MacOS, Linux) for uploading music
  • An Android device (for on-the-go music)
  • A Google account
  • Google Music Play app musiXmatch (if you use Android)
Read more

Today, I have released some minor update for tmtxt dired async library (an asynchronous execution library for emacs dired).

tmtxt dired async Homepage

The update fixes some minor issues and add some more features as below

Get size of multiple files

This feature uses the command du to calculate the total size of all marked files.

(define-key dired-mode-map (kbd "C-c C-s") 'tmtxt/dired-async-get-files-size)

Stop all current async tasks

This function helps you stop all currently running async taks.

(define-key dired-mode-map (kbd "C-c C-k") 'tmtxt/dired-async-kill-all)
Read more

Continue from my previous post Blogging using your favorite Text editor with Git and Jekyll - Part 1, this time, I’ll demonstrate some more advanced tips to help you get used to blogging with Jekyll.

Blog configuration

By default, Jekyll stores all your global site configuration in _config.yml file (can be found in the root directory of the site). Jekyll Bootstrap has comes with some pre-defined configurations that you can customize like Site title, Author information,… You can also customize post URL style using some Jekyll template variables followed the instruction here http://jekyllrb.com/docs/permalinks/.

One of the most important feature of a blog is the commenting system. Again, Jekyll Bootstrap has the built-in config to help you integrate a commenting system to your blog. Here is the example (you can see in the config file)

comments :
  provider : disqus
  disqus :
    short_name :
  livefyre :
    site_id :
  intensedebate :
    account :
  facebook :
    appid :
    num_posts: 5
    width: 580
    colorscheme: lightp
Read more

In my previous post Jekyll - Blogging platform for geeks, I have introduced Jekyll as well as its interesting features. This time, I wrote this post as a tutorial for those who want to build a static website/blog using Jekyll Bootstrap (an pre-implemented website in Jekyll), Git and hosted it on Github for free. Also, you can deploy it on your own server or use Github to host it with your custom domain.

Requirement

  • As I mentioned above, Jekyll is a blogging platform for geeks, not for newbie. You need to have basic knowledge about web programming and version control.

  • You also need to have your computer running Linux, MacOS, Unix or some similar operating system. You can still run Jekyll on Windows but it’s not encouraged and may cause some issue for you (Jekyll Documentation)

  • Choose a text editor that suitable for you. You can use any text editor that you. However, I recommend Emacs, Vim and SublimeText. In this article, I’ll demonstrate using Emacs (because I use Emacs) but it’s up to you.

  • The last requirement is to have Ruby, RubyGems and Git installed on your computer.

Read more
Agent 069 game
  •  02 May 2013
  •  misc 

Today, we have finish our first game on LibGdx name Agent 069. Actually, all 3 members in our group are programmers, not designer so that we are not good at designing and images so that game graphic is not very good. Also, when swpie up the screen to control the main character to jump up, it’s a bit laggy or slowly react, we still don’t know why.

Agent 069

The game is about X-rider (codename 069). He is a top undercover agent and CIA. He has James Bond’s charm, Bruce Lee’s martial arts mastery and Rambo’s gun skills. His latest mission is to infiltrate a terrorist headquarter deep inside a Chinese rural area. His main activity in this game is to escape from the terrorists after assassinating the boss and having his cover blown and his only tool is his trusty motorbike. 069 will go through 3 areas which are effectively the game’s 3 stages.

For more information like Download link, Game rule, Guideline, Screenshots as well as the Source code, please visit the the game’s homepage at Agent 069 Homepage.

Read more

Update: Now you can simply use https://jekyllrb.com/docs/posts/#post-excerpts

Jekyll does not offer Preview post feature by default. There are plenty of plugins that can help us achieve that task. However, since many Jekyll sites are hosted on Github and Github prohibits us from running plugins (maybe for security reason), we may have to deploy Jekyll site on our own server or generate the site locally and then push it onto Github. Today, after reading some Liquid documentation, I have found a solution that can help us show the preview of the post using only the built-in Jekyll Liquid tag with split and first filter.

Add separator for post

First, open a post and add this line where you want to split it. The text before it will be converted to html (if in markdown) and then show in the preview section.

Read more