From c967b1c22702e5a7a9cf477fe487b4003ba5b363 Mon Sep 17 00:00:00 2001 From: Gabriel Dunne Date: Tue, 3 Jan 2012 10:49:07 -0800 Subject: [PATCH] new articles and updated rss --- content/code/2012-01-02_arch_install_1 | 118 +++++++++++++++++++++++++ content/code/terminal_emulator_on_win | 85 ++++++++++++++++++ css/style.css | 45 ++++++---- lib/output.php | 18 ++-- pages/links | 6 +- templates/nav.html.tpl | 4 +- 6 files changed, 248 insertions(+), 28 deletions(-) create mode 100644 content/code/2012-01-02_arch_install_1 create mode 100644 content/code/terminal_emulator_on_win diff --git a/content/code/2012-01-02_arch_install_1 b/content/code/2012-01-02_arch_install_1 new file mode 100644 index 0000000..ea07c28 --- /dev/null +++ b/content/code/2012-01-02_arch_install_1 @@ -0,0 +1,118 @@ +title = arch linux install blog +date = 2012-01-02 +tags = arch linux windows installation tutorial +-- + + +Behold, a blog to document the process of installing [archlinux](http://www.archlinux.org/). Arch will be sharing the drive with Windows 7, so for the sake of completion, I'll make a note of how to set up a dual boot with the GRUB bootloader. I'll be installing both OS's from scratch, starting with Windows. + +
+## System Setup + +- AMD X2 dual-core processor, running at 2.8 ghz +- ASUS ATX motherboard +- 2 gigs of ram +- 100gb drive +- nvidia gtx 550 ti graphics card +- linksys wmp54g wireless pci network card +- 550w power supply + + +
+## Installing Windows +I installed Windows 7 from a USB stick using Microsoft's [Windows 7 USB/DVD tool](http://www.microsoftstore.com/store/msstore/html/pbPage.Help_Win7_usbdvd_dwnTool). You'll need a computer running Windows 7 already to do this. I booted with the USB drive, and installed Windows on the entire 100GB drive with a single partition. Once installed, via Start Menu > Administrative Tools > Computer Management > Disk Manamagent, select 'Shrink Partition' on the main Windows parition to create another partition for Arch. The default value for the shrink is 50%, so for my setup the value for the new disk size was ~50GB, and that's fine. + +Note about this install. I have an old Linksys (Cysco) WMP54G Wireless PCI Card. Strangely, all the drivers from Linksys/Cysco's website didn't work, but following this [blog post](http://www.phishthis.com/2009/01/16/how-to-install-wmp54g-drivers-on-windows-7-beta-64-bit-or-vista-64-bit/), the generic RALink drivers worked great. + + +
+## Installing Archlinux + +I downloading the Core Image via [torrent](http://www.archlinux.org/iso/2011.08.19/archlinux-2011.08.19-core-dual.iso.torrent) from [http://www.archlinux.org/download/](http://www.archlinux.org/download/). +This ISO includes all core packages so the system doesn't need to be online to install. + +Once downloaded, I followed my [notes](http://quilime.com/code/bootable_iso/) on how to create a bootable ISO onto another USB drive with yet another machine. There are also numerous free tools available to make a bootable ISO on Windows. After booting into Arch with the USB stick, boot into Arch, and type: + +
/arch/setup
+ +The [installation](https://wiki.archlinux.org/index.php/Official_Arch_Linux_Install_Guide) article on the archwiki is an excellent resource. + +You'll be prompted to chose your editor. If you don't know vi, then stick with nano. You can skip this, because you'll be asked again when it's needed. + + +
+## Disk Partitions + +It's pretty straight forward until the drive partitions. My 100GB drive can only support 4 logical partitions, so the rest have to be Logical. Note: The numbers are out of order, because I used Logical partitions for everything except for the Windows partitions and /home. Logical partitions end up being counted last in the partition table, but I made my /home folder LAST so I could use the up the remaining space on the drive. You'll also need to set the /boot partition's 'bootable' flag to `true`. + +
+• sda1  
+	Windows 7 System Reserved
+• sda2  
+	Windows 7  
+• sda5  
+	/boot - 100MB is enough
+• sda6
+	/ - about 25GB is appropriate
+• sda7
+	swap - between 1024MB and 4096MB
+• sda4
+	/home - use rest of hard drive
+
+ +Some of these, namely **boot**, **swap**, and **home**, are *optional*. + + +
+## Select Packages + +At minimum, you'll need the core packages that are already selected. I also included certain key packages such as OpenSSH. Basically, include any packages you need for internet connectivity, as everything else will be updated from the net. I use GRUB as the bootloader. + + +
+## Configure System + +Configure system does multiple things, including setting the root password, network settings, and some other configuration tools. Here's a reference of where Arch installs all the base config files for the system. + +
+/etc/rc.conf					system config
+/etc/fstab						filesystem mountpoints
+/etc/mkinitcpio.conf			initramfs config
+/etc/modprobe.d/modprobe.conf	kernel modules
+/etc/resolv.conf				dns servers
+/etc/hosts						network hosts
+/etc/locale.get 				glibc locals
+/etc/pacman.conf				pacman.confg
+/etc/pacman.d/mirrorlist		pacman mirror list
+
+ +You should edit any of these files that are specific to your system. At minimum I enabled my network card in `rc.conf`. + +You'll also need to enable at least one mirror in pacman.d/mirrorlist if you plan to update the system or download new packages. + + +
+## Bootloader + +Install Bootloader will install and help you configure the bootloader you selected in the Select Packages stage (GRUB, in my case). After double-checking your bootloader configuration, you'll be prompted for a disk to install the loader to. You should install GRUB to the MBR of the installation disk, in this case `sda1`. + + +
+## Finalizing Installation + +Once installed, exit the installer, remove the USB, type `reboot` in the command line, and the system will reboot. If all went well, you should be dropped into a login screen where you can log in with root and the password you chose during install. + +You can create [new users](https://wiki.archlinux.org/index.php/Users_and_Groups) interactively with `adduser`. + +You can install/update packages with Arch's package manager, [pacman](https://wiki.archlinux.org/index.php/Pacman). + +Before installing any packages, sync the package list with: + +
pacman --sync --refresh
+ +To add a new package (vim, in this case), type: + +
pacman -S vim
+ + +next: getting node and a webserver installed. diff --git a/content/code/terminal_emulator_on_win b/content/code/terminal_emulator_on_win new file mode 100644 index 0000000..7e0bc70 --- /dev/null +++ b/content/code/terminal_emulator_on_win @@ -0,0 +1,85 @@ +title = Terminal Emulator on Windows via Cygwin +date = august 11 2011 +-- +The default Cygwin install emulates a terminal in a command window similar to the DOS prompt with a limited feature set. + +For a full featured x-term, you can install Cygwin-X along with Cygwin: + +1. **Install Cygwin from setup.exe** + +2. **Install the following packages:** + + - xorg-server (required, the Cygwin X Server) + - xinit (required, scripts for starting the X server: xinit, startx, startwin (and a shortcut on the Start Menu to run it), startxdmcp.bat ) + - xorg-docs (optional, man pages) + - X-start-menu-icons (optional, adds shortcuts to X Clients and Server to the Start menu) + - mintty (windows-feel terminal) +
+ +3. **Optional Packages** + - openssh + - git, svn + - wget, curl + - rsync + - vim, emacs + - any additional fonts + +
+ +3. **~/.XDefaults** +dark theme: +
+! terminal colors ------------------------------------------------------------
+! tangoesque scheme
+*background: #111111
+*foreground: #babdb6
+! Black (not tango) + DarkGrey
+*color0:  #000000
+*color8:  #555753
+! DarkRed + Red
+*color1:  #ff6565
+*color9:  #ff8d8d
+! DarkGreen + Green
+*color2:  #93d44f
+*color10: #c8e7a8
+! DarkYellow + Yellow
+*color3:  #eab93d
+*color11: #ffc123
+! DarkBlue + Blue
+*color4:  #204a87
+*color12: #3465a4
+! DarkMangenta + Mangenta
+*color5:  #ce5c00
+*color13: #f57900
+!DarkCyan + Cyan (both not tango)
+*color6:  #89b6e2
+*color14: #46a4ff
+! LightGrey + White
+*color7:  #cccccc
+*color15: #ffffff
+
+Some more themes on the Arch forums. +
+ +4. **~/.bashrc** +To enable color `ls` and human readable size format, add: +
+alias ls='ls -h --color=tty'
+
+By default, the .bashrc in CygwinX has many options you can uncomment. +
+ +5. **~/.emacs** +Disable emacs temp (~) file pooping +
+(setq make-backup-files nil)
+
+
+ +Result: + + + +Other emulators for Windows: +- Terminator/ + diff --git a/css/style.css b/css/style.css index beb508a..c4b82c4 100644 --- a/css/style.css +++ b/css/style.css @@ -1,12 +1,14 @@ -body { margin: 20px 100px 50px 30px } +body { + margin: 20px 100px 50px 30px; + background:#eee; +} html, body, table { - font-family: georgia, serif; - font-size: 14px; - line-height: 1.4em; - color: #44d; + font-family: sans-serif; + color: #22f; + line-height:1.3em; } ::-moz-selection, ::selection { @@ -40,6 +42,8 @@ h5, h6 { font-family: 'Droid Serif'; font-size: 1em; + +color:#004; } h1 a, h2 a, @@ -48,7 +52,7 @@ h4 a, h5 a, h6 a { } h1 { margin: 0 0 3em 0 } -h2 { margin: 0 0 0.5em 0 } +h2 { margin: 0 0 0.5em 0; } h3 { margin: 0 0 0 0 } h4 { margin-top: 0 } ul, li { } @@ -66,21 +70,22 @@ blockquote { line-height: 1.45em; max-width: 600px; } -code { line-height: 2em !important; } +code { } #content { - padding-left: 160px; + padding-left: 100px; min-width: 500px; padding-bottom: 200px; z-index: 10; + } #content p:first-child { margin-top: 0 } -p { max-width: 720px } +p { } .nav { - position: fixed; top: 20px; left: 20px; + position:absolute; } .nav a { text-decoration: none; @@ -106,17 +111,26 @@ p { max-width: 720px } text-decoration: underline; font-weight: normal; } -.entry { margin-bottom: 100px } -.entry h2 { - padding-bottom: 4px; - font-size: 1.3em; +.entry, table .column { +margin-bottom: 50px; +background:#fff; +padding:30px; +border-radius:30px; +max-width:720px; +box-shadow:inset 1px 1px 1px #ddd; } .entry .metadata { + margin-top:3em; font-style: italic; - color: #bbb; + color: #999; + font-size:12px; } .entry .metadata a { color: #999 } .entry .metadata a:hover { color: #000 } +.tags { +margin:0; +padding:0; +} .entry .metadata .tags li { display: inline-block; margin-right: 0.3em; @@ -133,7 +147,6 @@ table { border: 0; } table .column { - padding-right: 100px; min-width: 120px; max-width: 400px; } diff --git a/lib/output.php b/lib/output.php index 502aa99..ec48186 100644 --- a/lib/output.php +++ b/lib/output.php @@ -125,16 +125,20 @@ function get_rss_feed( $url ) $xml = new SimpleXMLElement($feed); return $xml; */ - $ch = curl_init(); - curl_setopt($ch, CURLOPT_URL, $url); - curl_setopt($ch, CURLOPT_POST, 1); + $ch = curl_init($url); + //curl_setopt($ch, CURLOPT_URL, $url); + //curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); - curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 30); - curl_setopt($ch, CURLOPT_TIMEOUT, 5); - curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_ANY); - curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); + curl_setopt($ch, CURLOPT_HEADER, 0); + //curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 30); + //curl_setopt($ch, CURLOPT_TIMEOUT, 5); + //curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_ANY); + //curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1); $data = curl_exec($ch); + //echo $data; + //echo "sf"; + //exit; curl_close($ch); return new SimpleXMLElement($data); diff --git a/pages/links b/pages/links index 8a3369e..574c877 100644 --- a/pages/links +++ b/pages/links @@ -2,7 +2,7 @@ title = links type = page markdown = true -- -people +people/groups ------ + gabriel dunne [gabrieldunne.com](http://gabrieldunne.com) + stephanie sherriff [ssherriff.com](http://ssherriff.com) @@ -12,7 +12,6 @@ people + keith pasko [keithpasko.com](http://keithpasko.com) + jeff lubow [dabkitsch.com/jml/](http://dabkitsch.com/jml/) + michael chang [ghost-hack.com](http://ghost-hack.com) -+ carbon workshop [carbonworkshop.com](http://carbonworkshop.com) + sascha pohflep [pohflepp.com](http://pohflepp.com) + mylinh trieu [mylinhtrieu.com](http://mylinhtrieu.com) + aaron meyers [universaloscillation.com](http://universaloscillation.com) @@ -30,5 +29,6 @@ people places ------ ++ carbon workshop [carbonworkshop.com](http://carbonworkshop.com) + gray area foundation for the arts [gaffta.org](http://gaffta.org) -+ bay area video coalition [bavc.org](http://bavc.org) \ No newline at end of file ++ bay area video coalition [bavc.org](http://bavc.org) diff --git a/templates/nav.html.tpl b/templates/nav.html.tpl index 64bc3f6..b0cd97d 100644 --- a/templates/nav.html.tpl +++ b/templates/nav.html.tpl @@ -1,7 +1,7 @@