After using different methods to get email, I decided to go back to using Offlineimap.
I updated the configuration file I was using before and ran it. It "worked". It would sync all the email account but the postsynchook wasn't running.
In the old .offlineimaprc file, the "postsynchook =" was the last line in the file.
i.e.: [Account XXX]
postsynchook = xxxxxx
In order to get it to run, I had to move it up to just below the [Account XXX] section:
postsynchook = xxxxxx
Note: There are multiple accounts in the offlineimaprc file but only put one postsynchook command after the Account section of the last account so the indexer only gets executed once per sync.
Wanted to try something new so I switched from using virtualenvwrapper to Python Env Wrapper, aka pew for my Python virtual environments.
(This is an ArchLinux system.)
Remove the python entry from the .zpreztorc file (which setup the WORKON_HOME env variable).
Then, remove virtualenvwrapper from the system:
yaourt -Rns python-virtualenvwrapper
then rebooted to MAKE SURE the environment came up clean.
The install and setup.
yaourt -S python-pew
Since I am using Nikola to create this website, I:
pew new valencering
This created the new virtualenv, launched a new sub-shell and added the text "valencering" to the left side of the prompt but it didn't set the project directory.
So I cd'd to the working directory and ran:
pip install --upgrade "Nikola[extras]"
and then ran nikola build.
And it worked.
I exited the sub-shell and the prompt changed back to "normal" and nikola was no longer a valid command.
I then ran
pew workon valencering
It set the virtualenv but didn't take me to the code. So again, I cd'd there manually.
With the virtualenv activated and in the "home" directory I ran:
Now, no matter where I am, if I run:
pew workon valencering
it will take me to the code and set the virtualenv just like virtualenvwrapper would do.
Looking at the Command Reference, I could have done all this in one command:
cd to the working directory pew new -a $PWD valencering
One other difference is that the default location for the virtual environments is now at ~/.local/share/virtualenvs, whereas before, both oh-my-zsh and prezto set it at ~/.virtualenvs but it could be overridden with environment settings.
When a virtualenv is activated and it displays an error message similar to:
dyld: Library not loaded: @executable_path/../.Python
The symbolic links to the Python executable are broken.
Pretend the virtualenv is located at ~/.virtualenv/myapp.
Go to the virtualenv directory, delete the links, re-link Python:
find myapp/ -type l -delete
Go to the directory of myapp and activate the virtualenv and it should work.
Working offline (no internet), create a new virtualenv based on an existing virtualenv:
mkvirtualenv (and virtualenv) are installed
pip install virtualenv-clone
Then, to create a new virtualenv:
virtualenv-clone /path/old-virtualenv /path/new-virtualenv Use workon to activate the new virtualenv Create a directory for the new project and cd into that directory. setvirtualenvproject
A quick checklist to setup Cordova (PhoneGap) and Android to create Mobile Apps on a MacBook Pro running Mavericks.
The Manual Way
Go to a website like What's my IP to get your current IP address.
Log on to the Google Analytics site.
Click on the "Admin" button and then click on "All Filters" in the left sidebar.
Click on "Add a new Filter" and create a new filter.
Input the IP address you got from What's My IP Address and save the filter.
This is a "checklist" for setting up a MacBook Pro running Mavericks.
Start: Completely clean MBP with Mavericks installed.
Goal: Have a nice system that will be used for mostly development but some entertainment using mostly FOSS software.
OMZ has both a virtualenv and a virtualenvwrapper plugin.
In the past, the .virtualenvs directory was located at $HOME/python/.virtualenvs and the instructions for installing virtualenvwrapper required the addition of some exports to the .bashrc file.
The plugins take care of the exports but the default location for virtual environments is now at $HOME/.virtualenvs.
One more "converting to zsh" issue:
When commiting a change using the "gc" command, git would report this error:
error: There was a problem with the editor 'vi'.
Change the editor = vi to editor = vim line in .gitconfig.
There was probably either an alias or a symbolic link to make "vi" = "vim" but that doesn't exist anymore.
Recently switched over to running ZSH on a MacBook Pro and also installed Oh-My-ZSH.
Added the tmux plugin to .zshrc and it worked.
Tried to use the same .tmux.conf file from "Bash land" and the keys worked correctly but the shell changed back to Bash.
Had to make one change to the tmux.conf file:
``set-option -g default-command "reattach-to-user-namespace -l bash"
``set-option -g default-command "reattach-to-user-namespace -l $SHELL -l"
This allows the OMZ script to run properly and now displays the correct prompt.