Installation from scratch : Ruby 2.0.0 under Windows ruby 2, windows, sqlite3, ansicon, console2, conemu, git
- Console2 2.00b147
- Configure PATH for NTLM Proxy
- Ansicon 1.60
- Ruby 2.0
- DevKit 4.7.2
- SublimeText2
- Configure ST2
- Install the Package Manager ST2
- Install some plugins for ST2
- GIT
- SQLite3 3.7.15.2
- Your Ruby library : GEM
- And finaly Rails 4 !!
First set up some tools. Console2 was for longtime my shell manager, but i’ve discovered recently ConEmu which has more pretty options.
Console2 2.00b147
Download Console2. You’ll need to install ANSICON for managing colors (ConEmu do not need ANSICON), see below.
Configure PATH for NTLM Proxy
In case you’re under some NTLM Proxy, you’ll need to set some variables :
set HTTP_PROXY=http://proxy.adress:proxy_port
set HTTP_PROXY_USER=userxxx
set HTTP_PROXY_PASS=passwordxxxx
I used to centralize all my install into one directory c:/dev and puts all single .exe or .dll under c:/dev/bin and put those in PATH (ie : for SQLite3 dll and exe, LAME library, ffmpeg, …).
Ansicon 1.60
For nice console output : Ansicon. Download it and put the file under c:/dev/bin. You can register it for automatic launch in each console :
ansicon -i
ConEmu doesn’t use Ansicon.
Ruby 2.0
Download and install Ruby 2.0 : RubyInstaller for Windows (under c:/ruby200). Check it :
ruby -v
DevKit 4.7.2
Download also on RubyInstaller for Windows the right DevKit (version 4.7.2, 32 or 64 bits) and install it under c:/dev/devkit. Check the PATH :
echo PATH
>>... c:/dev/devkit/bin
And test the first Unix commands :
sh --login
ls -l
exit
The home directory is c:/dev/devkit/home/(user). I’ve created a .profile file here for configuring some alias :
alias ls="ls --color"
alias ll='ls -l'
alias w='which'
alias e='exit'
alias st="C:/'Program Files'/'Sublime Text 2'/sublime_text.exe"
SublimeText2
Download and install it SublimeText2.
Configure ST2
In menu preferences / Setting - Default, some modifications
"font_face": "Consolas",
"font_size": 10.0,
"tab_size": 2,
"translate_tabs_to_spaces": true,
"folder_exclude_patterns": [".svn",".keep", ".gitignore", ".git", ".hg", "CVS"]>
"file_exclude_patterns": ["*.pyc", "*.pyo", "*.exe", "*.dll", "*.obj","*.o", "*.a", "*.lib", "*.so", "*.dylib", "*.ncb", "*.sdf", "*.suo", "*.pdb", "*.idb", ".DS_Store", "*.class", "*.psd", "*.db"],
Install the Package Manager ST2
SublimeText has many usefull plugins, and a good package manager. Follow the instructions under Sublime package control for the installation. If you’re under a proxy, change your settings : Preferences / Package setting / Package control / Setting - Default :
"http_proxy": "http://proxy.name:port",
"proxy_username": "",
"proxy_password": ""
Install some plugins for ST2
Check the community site for the packages : community package control, and try them :)
For SublimeTODO package, change the settings (menu preferences / setting user), ie :
"todo":
{
"case_sensitive": true,
"file_exclude_patterns":
[
"*.css",
"*.po",
"*.mo"
],
"folder_exclude_patterns":
[
"static",
"vendor",
"tmp"
],
"patterns":
{
"BUG": "BUG[\\s]*?:+(?P<bug>.*)$",
"TEST": "TEST[\\s]*?:+(?P<test>.*)$"
},
"result_title": "TODO Results list"
}
GIT
Some good reading link (fr/eng) for starting :
- http://rogerdudler.github.com/git-guide/index.fr.html
- http://www.siteduzero.com/tutoriel-3-254198-gerez-vos-codes-source-avec-git.html
- http://www.pierreschambacher.com/blog/git-in-a-nutshell/
- http://git-scm.com/book
In first, install GIT for Windows under c:/dev/git
Configure Console2 for the git bash shell :(console settings / tabs) :
- Title : Git
- Icon : c:/dev/git/etc/git.ico
- Shell : C:\WINDOWS\system32\cmd.exe /c ““C:\Dev\Git\bin\sh.exe” –login -i”
You can either configure ConEmu with the same command line.
Launch a new shell and check :
git config -l
and eventually modify them
git config –-global user.name xxx
git config –-global user.email xxx@xxx.com
git config --global core.editor vim
git config color.ui true
git config format.pretty oneline
git config --global http.proxy http://user:password@proxy.adress:port
Check again :
git config --list # pour vérifier
You can use SublimeText as Git editor :
git config --global core.editor "'c:/program files/sublime text 2/sublime_text.exe' -w"
SQLite3 3.7.15.2
Go on SQLite and download ‘precompiled binaries for windows’ : - sqlite-dll-win32-x86-…zip : the dll - sqlite-shell-win32-x86-…zip : the shell SQLite
Copy all of them under c:/dev/bin (so they are in the PATH) and test :
sqlite3
.help
.quit
Your Ruby library : GEM
First update :
gem update --system
And the others :
gem update
And finaly Rails 4 !!
gem install rails --version 4.0.0.beta1 --no-ri --no-rdoc
rails -v
rails server -p 80
And … normally you’ll get some nasty bug here from SQLite3 :) Don’t worry, check the next article.
Tweetcomments powered by Disqus