WordPress.org Vs. WordPress.com How to start with WordPress.com

Here is my presentation for Wordcamp Birmingham 2009.

For those who want a quick guide to getting going in WordPress. I presented the following at WordCamp Birmingham: After looking through it you should be well on your way to setting up your own site.

It is a pretty basic intro to what can you do and how to do it with WordPress.com
Hope it helps, feel free to ask questions in the comments, I’ll try to answer.
If you click on the headline below you will go to the Slideshare site where you can also see the speaker notes, below the slides (notes tab).

Presentation At SlideShare with notes.

Book Review – Pragmatic Version Control Using Git

Review published at DZone: http://books.dzone.com/reviews/book-review-pragmatic-version

I believe one must have a reasonable acquaintance with at least the three big guns in version control for open source, Subversion, known as SVN (non distributed), Mercurial and GIT.
Pragmatic Version Control Using Git The Pragmatic Starter Kit-Volume 1 By: Travis Swicegood ©2008 ISBN-10: 1-934356-15-8 Publisher: The pragmatic Bookshelf Raleigh, North Carolina, Dallas Texas. $34.95. note that this is version 1.0 of the book, version 2.0 just came out. We are still trying to determine from the publisher if version 2 is out, they say no but the web site says yes?

Git is rapidly becoming the major opensource distributed version control system (DVCS) of choice for many major projects. Competitors such as Mercurial and Bazzar (both DVCS) are important and SVN remains as a major centralized VCS. It has become quite necessary to have at least a basic understanding of each of these systems if you are active in the Open source world. Of these systems arguably the most complex is and comprehensive is git.

Git was originated by Linus Torvalds to help manage the distributed development and merge processes involved with the maintenance of the Linux kernel. It is something of a rite of passage for open source developers to become sufficiently fluent with its use.

The basic documentation on the net and even Linus’s famous talk (available on you tube) got me started but I still have been feeling a bit lost.

While this book is targeted at rank beginners there is plenty here for the advanced user. It succeeds admirably in providing information for all levels of users.

As someone quite new to Git, I found this book to be very well laid out and it has a huge virtue of making no assumptions! I believe that much of the other material I attempted to learn from made big assumptions either about Version Control knowledge from other systems or just plain skipped over concepts and presented raw commands, leaving it to the reader to determine how and when to use what command.

The book gently starts out describing the general case of version control and rapidly introduces clear cogent explanations of how git differs from centralized systems. At the same time the introductory portions of the book use basic examples to introduce versions of various concepts along with the related commands.

I found myself saying often as I read, oh! that’s the way it works!

I also found myself trying to understand more about some of the actual mechanics. This is where another great feature of the book came to the rescue for me. Each chapter has a Git hub repository which you can access to try out each concept or command that is being discussed. That filled in a few holes for me, specifically, for instance, what state is the working directory in and how does a command affect the working directory.

For me the book rates about a 8.5 out of 10, the only thing that might have improved it for me would have been some Tortoise Git explanation. I could also use more on setting up your own repository on various services. This criticism is unfair since Tortoise Git really only became viable after the book was put to bed and there is simply too many variables between hosting providers to cover that point adequately. The material presented is a definite help getting started with the task and I’ll have the book open as I start to work on that for myself. The book also has a web site which has errata, and other comments which may prove helpful http://www.pragprog.com/titles/tsgit/pragmatic-version-control-using-git

Some Windows Pinax help

This is just an overview: See the Wiki here for the nitty gritty…

For widows users: 1st thing which is not obvious is that all the installation steps must be done from the command shell in windows (preferably in admin mode if on Vista), from the correct directory. You do not use the python idle environment, nor do you explicitly invoke python, (except at the very end!!)

You must have SVN and GIT installed and on your path (which the “normal” installations take care of) note that Tortoise SVN is not sufficient (It does not have the command line interface) Slik svn does http://www.sliksvn.com/en/download, both can co-exist, Tortoise Git  http://code.google.com/p/tortoisegit/ is a good install for windows users and includes a complete tool set. The boot and install scripts depend and use these programs to install source code from many locations/libraries, really very cool…therefore you must have a good internet connection!!

You should probably execute the command shell with the “run as administrator” if using Vista, if xp you should be an administrator.

You do not need to do a checkout or download of any files other than the “pinax-boot.py” file, which should be placed in a directory that you want to use as your base installation directory.

a general outline of what happens…..
You run pinax-boot.py
It downloads the base Pinax repos and installation scripts.
You “activate” pinax-env
(it is really running in the command shell)
That changes your prompt. You will then do your directory changes within this new pinax-env prompt……
(this took a while for me to wrap my head around but I now agree that it’s a really neat good idea!!, I would not try without it)
pip install <<<this step processes a very long and involved script which gets numerous dependent/pre-requisite packages and places them properly in the “virtual-environment”
you remain in pinax-env all during this process….and following….
pinax-admin clone_project retrieves the proper stuff from the set of files that you have downloaded and sets up another directory containing just your project as a django project…
It is a good idea to go with the default sqllite db (ie. don’t touch settings!!)
Now follow the directions, again from within pinax-env,, and cd into your project directory and runserver.. You should get a nice pinax complaint about no db.. follow the instructions to syncdb and so on…

See the Wiki here for the nitty gritty…

Shooting myself in the head with Python, Django,Pinax

Well I decided to take some time off from working with the App-engine-patch and try Native Django,, go more mainstream so I could take advantage of more robust database and tutorials…

I’m using Python 2.62 Win 64 Eclipse 3.4 Ganymede, and trunk SVN Django 1.1

1st, one must install a Mysql driver The one in the “official library won’t work, version differences.. go here for a windows installer for Python 2.6 https://sourceforge.net/forum/forum.php?thread_id=2316047&forum_id=70460  Fwiw I’m using 32 bit versions although there is a 64 bit version available (for both Python and the Mysql driver (lower down on that thread).

You also need to add the following change manually to the Mysqldb code

About warnings:

1) file “__init__”, replace:

from sets import ImmutableSet
class DBAPISet(ImmutableSet):

with

class DBAPISet(frozenset)

2) file “converters.py”, remove:

from sets import BaseSet, Set

3) file “converters.py”, change “Set” by “set” (IMPORTANT: only two places):

line 48: return set([ i for i in s.split(‘,’) if i ])
line 128: set: Set2Str,

I hope this be useful.

Regards,

Luis Moreno

I realized That I had not been documenting myself when I blew up and was about ready to re install and realized I’d have to look every thing up again… Hence back to posting!

One of the most interesting revelations for me recently is how Python “installs” and referrers to packages and extensions. At this point I now think that all the trashing about is a bit too much on many installs. Looking in site-pkges in Libs in the Python directory I noticed several .pth files named for some of the extensions I was installing and using, the file was the module name.pth.. and contained the full path to the module… cool! So that is a mechanism that can be used to create a nice place to keep that stuff without messing up your basic Python install… good to know..

Another major revelation has been the use of revision control systems,,, It seems that it is well worthwhile to have a copy of all of the major systems on your machine. Git, SVN and Mercurial. If you checkout a copy of a system like Django,,, then when you want a update to the current version just do another checkout and your done!

Btw it turns out that even if you use TortoiseSVN as I do it is a good ides to install Silk SVN also because Tortoise does not provide command line access, which is used by some packages for automated installation/updating, in particular Pinax! So even if you don’t want command line you need to have it on your system…

If you use tagging with the 1.0 or latter Django you must use the svn version of tagging ….

Google App Engine Patch Django Examples

5/8/2009 update, I’ve added a link to a very rough video I gave at Barcamp Birmingham on “An Introduction to Google App Engine and App Engine Patch” (it’s there but WordPress does not like to “preview Vimeo for some reason!).

I have not posted to this Tech blog for a while but I have been continuing my learning process. I’ll try to point out some key developments for me and that may help you out.

This is already a bit out of date but illustrates some key concepts which I was having problems with as I learn Django, app-engine, app-engine patch and Python and expand my limited knowledge of css/xhtml.. (so is that enough disclaimer?!)

Many thanks to Waldemar Kornewald, author of the AppEngine Patch (AEP) and
Konrad Martin who graciously provided the screenshots of how to integrate css (and other media, in the Django lingo) into AEP, which for me was way more clear than the documentation, with my very limited understanding of basic Django concepts. Since Konrad provided this Waldemar has updated the AEP ‘Package” to include examples which also now include javascript. I have not yet had a chance to load that up and play with it but the concepts presented in these screen shots should still be very helpful to all. While Konrad provided them for download from an Appspot domain here I felt that having the screen shots available without having to download anything would be helpful to many. Konrad has added some more screenshots with some layout ideas here. (added 4/16/2009).

I cannot add much to the screen shots they are very well annotated. The original discussion is here.

You may click on the image to get a larger version, then again to get a fairly full sized version, they are in order of operation.

Eclipse/App Engine/Bloog Part 4, The hard part

Well I had a long and frustrating week/week-end, all sort of run together. I discovered that my new site would not take even moderately long articles. This is apparently a “known problem” and it relates to exploding indexes, as somewhat explained here.

I finally got to corresponding with one of the Bloog Maintainers who had it turned out created a modified site search capability using Google Site Search. According to him  it still does not provide for longer article without some code mods that I have not yet started. But is a prerequisite. I got a copy from Git-hub, where Bloog is hosted. This required that I get and install GIT version control system. I chose to start with Windows based  Git Extensions. It still required that you install the basic GIT. It is only available in Tar format you will need 7zip to unpack although after a posting the developer has now provided a “full” option for Git extensions.

I then tried to apply the new code to my existing Bloog version as I had modified it. That required a differential editor,which I did not have Kdiff3 turned out to be a great choice. It compares entire directory structures and than lets you click through the files and selectively choose to apply a, b to your revised file. Very cool.

I then tried to fire things up, FAIL. I then went back to the Version I had just obtained and I could not get it to fire up either. I then started to look for “real” debug information. Not much available.

Eventually I downloaded PYdev for Eclipse, and that was a major improvement  my entire development environment. In fact I would go so far to say Do not attempt development for APP-Engine without Pydev!! It provides a much better editor, code outlining and a runtime environment. There are several tutorials on setting up Eclipse for app-engine. Use them!!! Supposedly it also provides breakpoints, but I have not been able to get that working yet, but the other improvements are a major joy. The Debug environment did give me better log messages. Through which I was eventually able to make some headway. I found out that the two versions had changed the DB schema slightly so I had to delete a few older records You can see and modify the local datastore using http://localhost:8080/_ah/admin/datastore and bang it all started to work. It actually took a long time to go through each step, and I still have to go back and learn each of the new tools much better.

APP Engine Using Bloog Part 3 Upload the app

Well, after I got the framework for my new Blog (based on Bloog), going using my local debug server it was time to upload the app and get it live. The instructions simply said to run apcfg.py with a few parameters… Two issues, where to run the command and how to get all the parameters, I got some good help once again in the group. It turns out the command must be run in a Windows Command window, (not exactly intuitive but now that I know it it makes sense!) I placed my cmd window back to root using the cd\ command then ran c:appcfg.py update c:\Users\DadLaptop\Documents\tombrander Note that I did not have any spaces in my directory string, for some reason I could not get the cmd to work within a quoted string as one of the responders suggested, also it does not work in a bat file. Also a subsequent post suggested how I might be able to use cut and past in the Vista cmd window, as follows, (have not tried yet)

You can copy and paste by using the System menu of the window. You can open this menu by using Alt-Space or click on the top left icon in the titlebar (for a cmd window it is a small c:\) In this menu you find a submenu for clipboard operations. If you want to copy text to the clipboard you first have to “Mark” the text and then press “enter”.

Great, now the whole thing was on the internet and working, mostly. I did a few test posts. A bit later I tried the Mail and comment functions,,, FAIL, back to the groups…. I investigated myself and posted the logs,, I was beginning to wonder if the Gmail name in the config.py file was case sensitive… I changed it to all lower case and reran the Update function as discribed above and low and behold both the comments and mail function started to work! Now I have the basics going. Content and refinement to come!