Wednesday, 16 January 2013

Launched rebranded and now responsive Luxury travel site Mirus Journeys

Launched a site rebrand under a new name of Mirus Journeys this week while at Wild Dog Design - http://www.mirusjourneys.com/ Its my first big responsive site (based on Joomla 3 for those who are interested). Been a nice project to work on and John who did the front end dev and Stan who did some of the design have been good to work with. What do you think?

Tuesday, 4 December 2012

Whats more exciting than an Arduino

Whats more exciting is getting one in the post and thinking of what to build with it. I have wanted to build something with electronics for a long time but electrical diagrams and believing it a bit hard have put me off. But I went to the Build Brighton hack space last week where they did an evening on RaspberryPi, and Python. Python I can do and the stuff some people were building with trail and error excited me again. Looking at the two systems RaspberryPi is more a full computer but small, and Arduino is much smaller but better to interface with. Even better you can stick an Arduino on a Pi for greater flexibility. So though I would like to program it in python I think starting with an Arduino will be better as I'll have to work my way round 32k rather than a high celling of power. So on my christmas list is lots of electrical tools and kit. Hope I can get my son interested in pressing buttons and lighting LEDs too. http://www.ebay.co.uk/itm/120948981096?ssPageName=STRK:MEWNX:IT&_trksid=p3984.m1497.l2649 This is the kit im starting with A new world of Sketch and soldering awaits. (Interested if you are also doing the same?) :)

Monday, 11 June 2012

Top Chef Chris Bailey first Popup Restaurant in Brighton

My favorite Chef Chris Bailey starts his first Popup Restaurant in Hove, Brighton. He is calling it "Chris Bailey's ‘Taste of cheese’ Menu" Looking forward to the cheese inspired menu taken from the host Cheese Shop La Cave in Hove.
He is doing a 6 course amazing menu for just £35 a head. From talking with him the tickets are going fast and it should be great night.
I hope I can squeeze in to this one but am looking forward to making it to the next one he puts on in a few weeks too.
p.s. he is my brother but I did not get him a Michelin Star his great cooking did ;)

Tuesday, 8 May 2012

Learning to make vim fast and lovable editor

.. Or settings and tips I have learnt to make vim nicer, but are not on by default. ( I will keep adding to this )

I am using vim as my main editor for a few years but since freelancing I am learning to use it even more.

Vimrc settings

My changes to vim at the moment look like this

syntax on
set bg=dark 
" indent
set cindent
set smartindent
set autoindent 
" tabs
set expandtab
set shiftwidth=2
set tabstop=4
set showmatch " Show matching brackets.
" auto complete + C-n
set showcmd " Show (partial) command in status line.
" case search
set ignorecase " search ingore case if all lower search
set smartcase " Do smart case matching (flips igonore if use any caps)
set incsearch " search as type
" highlight search
set hlsearch " highlight all searches " :nohlsearch
"set visualbell
"set cinkeys=0{,0},:,0#,!,!^F
set cinkeys=0{,0},:,0#
set cinwords=if,else,while,do,for,switch,case   " Which keywords should indent
imap <C-e> <esc>$a
imap <C-l> <esc>g_
:nmap <C-n> :tabnext<cr>
" Press Space to turn off highlighting and clear any message already displayed.
:nnoremap <silent> <Space> :nohlsearch<Bar>:echo<CR>
" Press F4 to toggle highlighting on/off, and show current value.
:noremap <F4> :set hlsearch! hlsearch?<CR>

Outside of the config you can open files in tabs inside vim and then tab between them
vim -p file1 file2 file3
then use 'tg' to go to the next tab

Open a grep search of files as tabs in vim
vim -p `fgrep -l cust_function core/*.php`
This would search for 'cust_function' in the dir core for php files

Vimdiff - visual character level diff from cmd line

vimdiff is much nicer to look at if you have to understand merging files on the cmd line.
if you migrate from

line by line without checking white space (so ignore tabs/spaces which can change with editors and versioning)
diff -w filea.php fileb.php
 files side by side if you need to see context of more than a couple of changes
diff -wy filea.php fileb.php
In this view you can scroll up and down but right edge gets cut, you can see marks in middle of page
| different
> change to right version
< change to left version

But those two show only lines. Vimdiff shows colours to show character changes and move around in a visual way
 vimdiff filea.php fileb.php
And if you add this to ~/.vimrc you dont see the white space changes which is nice.
set diffopt+=iwhite
When in vimdiff you can move between windows and also which is nice, push and pull changes between versions.
So move to change "dp" pushes change from left to right side. The other way "do" pulls it from right to left

To switch windows in vimdiff or to navigate windows in vimdiff or to change windows in vimdiff try the following: The ":vertical" command can be inserted before another command that splits a window. 
MOVING BETWEEN WINDOWS          
CTRL-W h        move to the window on the left         CTRL-W j        move to the window below
CTRL-W k        move to the window above 
CTRL-W l        move to the window on the right         CTRL-W t        move to the TOP window      
CTRL-W b        move to the BOTTOM window 
Moving windows  
CTRL-W K        move window to the upper 
CTRL-W H        move window to the far left
CTRL-W J        move window to the bottom         CTRL-W L        move window to the far right 

Have Vim jump to the last position when reopening a file
if has("autocmd")
  au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$")
      \| exe "normal! g'\"" | endif
endif

Auto complete comment block lines.
" In edit mode
" #b<return>
" type text
" #e<return>
:ab #b /************************************************
:ab #e ************************************************/
:ab #l /*----------------------------------------------*/

Show hidden characters, leading and tailing white space with
:set list
Then you can see if you have lots of white space as $ will be on end of lines
Next you can run a zap trailing white space
:1,$s/[ <tab>]*$//
and off with
:set nolist

source: http://www.oualline.com/vim-cook.html

Not quite vim but useful

You can get a sort of auto complete from your history file. So for example
cd PageUp
changes to
cd /file/path/i/used/earlier

or if your jumping around
cd /file/path/PageUpPageUp
becomes the last bit
cd /file/path/i/used/before/that

Change it here:
vim /etc/inputrc
Then uncomment the lines for using PageUp and PageDown to fill the rest of your cmd propt from your history
# alternate mappings for “page up” and “page down” to search the history
#”e[5~”: history-search-backward
#”e[6~”: history-search-forward

Friday, 27 April 2012

Freelance project work in Brighton or Remote from home

As we come into May 2012 I am looking for Freelance Web Development project work in Brighton or Remote from home from end May and June onwards.
Any sort of updating websites or maintaining them or building them new. I am a PHP web developer and also to project strategy and Social Media and SEO supported by Web Analytics.

So you could be anywhere in the world but I live in Brighton so will be talking to you from here or meeting you near by.

thanks

tristan

Thursday, 17 November 2011

This week I have mostly been looking for freelance work and django

This week I have mostly been getting my head into Python and learning django for my new blog/portfolio site. I want to find some more evening feelance work so time to get my pencil and code out on something for myself and get my self a new site so I can show some of the work I have been doing and see if I can get some more.

Things I have learnt about django so far that had caught me out:
It caches code to memory so use the test server and restart alot, this caught me out as sometimes files would update and sometimes not.
The django 4 stage tutorial is good and worth doing but I was trying to skip ahead and bring in other snippets for template creation and they were breaking because I had missed some small details on imports. So worth going slowly. The tutorial is nice as it does things basically and then goes back and layers over the last function with more features so you build up knowledge.

Thursday, 15 September 2011

Still here

Not so happy with the new minimal Blogger so am learning more Python and django so will be seeking to have some hacking weekends next month and get something new up and make more effort to post a bit. I find twitter so easy to brain dump, share and blog in that its hard to take the time to write more.

1. get fit
2. get a django site up
3. post more blogs