Archive for category Ubuntu
Have you ever wanted to just have a list of the machines on your network? One that you could easily pass to a script / application? Well I sure have. So I do the
net view > outfile.txt then scrub the text file dance. All I really want is a list of the machine names. No \\ in front of the names. No description of the systems either. I want to go from this:
\\comp1 my computer \\comp2 \\comp3 test machine
comp1 comp2 comp3
So today I decided to write a little crap script to do this for me in one step. I know it isn’t pretty but I don’t really care. I just want it to work. The good thing is that I can now use the same kind of code in some of my other scripts and I don’t even need it to write to a file at all.
#!/usr/bin/env python import os outfile = open(r'pyNetView.txt', 'w') indata = os.popen('net view') for line in indata: if line.startswith('\\'): line = line.split() clean = line[2:] outfile.write(clean + '\n') outfile.close()
Comments are welcome. Use it if you want.
I have been wanting a cool new phone for quite some time now. I first fell in love with the iPhone (I don’t care that it is not open source). Then like most geeks I know the G1 was my new item to desire. I am half way through a contract right now with AT&T and they will not let me get the iPhone at the discounted price. Being in the contract means that I can’t switch over to TMobile to get the G1 either. Bummer huh.
Last night my wife and one of our friends went to a party. While there I met a girl that has a 3G iPhone that she has only had for about a month. She said that she would rather go back to her old phone and that she would sell it to me for $100. That is a heck of a deal right? The sad thing is that I don’t have $100. 3 kids are depending on us to have a good Christmas this year. On the other side of that coin my wife said that she wasn’t sure that even if we did have the money to get the phone that we may not have the extra money each month to pay for the iPhone data plan.
It sucks so bad being a poor geek
- Grab the nearest book.
- Open it to page 56.
- Find the fifth sentence.
- Post the text of the sentence in your journal along with these instructions.
- Don’t dig for your favorite book, the cool book, or the intellectual one: pick the CLOSEST.
The Kentucky LoCo / BGLUG teams are having a release party for Ibex this Saturday. The event will be at Eastside Technical Center in Lexington from 2pm to 5pm EST. We received our CDs about a week ago and we are ready to pass them out to any that wants them. All are welcome to come and help us celebrate.
OK. I cheated a little. This is a picture of me and my daughter taken just for this meme. It was hard to get the glare from the laptop camera (cheese) to not be on my glasses.
- Take a picture of yourself right now.
- Don’t change your clothes, don’t fix your hair…just take a picture.
- Post that picture with NO editing.
- Post these instructions with your picture.
If you are in the Kentucky area next weekend (9/20/08) come and celebrate SFD with us. You can find more information about the team I am working with here.
Thanks to this blog post I have started using Editra for my coding needs. It at version 0.3.38 which is its 14th alpha release at the time of this writing. Don’t let the alpha part fool you though. It is a very nice app that has some good features. It has syntax hilighting for 60+ languages and code completion built in for python code. It has a plugin manager for easily installing some extra features. For a list of the currently available plugins see here. The one thing that I would like to see is the addition of hg as a vcs in the Projects plugin.
If you decide to try it out please post any bugs that you find in the projects bug tracker. If you are on irc.freenode.net then drop by the projects channel at #editra.
If you are a Foresight Linux user then you can try out the editor by running:
sudo conary update Editra=foresight.rpath.org@fl:2-devel