This repository has been archived by the owner on Jan 29, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
atom.xml
768 lines (581 loc) · 71 KB
/
atom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title>Eddie Hedges</title>
<link href="http://edhedges.github.io" />
<link href="http://edhedges.github.io/atom.xml" rel="self" type="application/atom+xml" />
<updated>2015-12-31T15:05:05-06:00</updated>
<id>http://edhedges.github.io</id>
<author>
<name>Eddie Hedges</name>
<email>[email protected]</email>
</author>
<entry>
<title>I got a Pi for my birthday!</title>
<link href="http://edhedges.github.io/blog/2014/08/07/i-got-a-pi-for-my-birthday"/>
<updated>2014-08-07T00:00:00-05:00</updated>
<id>http://edhedges.github.io/blog/2014/08/07/i-got-a-pi-for-my-birthday</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><h4 id="no-that-isnt-a-typo">No that isn’t a typo…</h4>
<p>I received a <a href="http://www.raspberrypi.org/">Raspberry Pi</a> for my birthday! I got the <a href="http://www.mcmelectronics.com/product/83-16332">Raspberry Pi Model B+ Starter Kit</a> and
I just felt like giving back to the awesome community by sharing my experience and setup.</p>
<h4 id="in-the-beginning">In the beginning</h4>
<p>I feel like I started my adventures into the world of the RPi (short for Raspberry Pi in case you didn’t figure it out) a step
ahead of the norm because I didn’t have to go through any manual os download and install. The starter kit I purchased came with
<a href="http://www.raspberrypi.org/introducing-noobs/">NOOBS</a> installed, so all I had to do was plug everything in and select the distros to install on my microSD card. I installed
Raspbian and my initial set up worked fine, but <a href="http://i.imgur.com/3HKwSso.jpg">it was not aesthetically pleasing</a> and needed some configuration and improvement.</p>
<h4 id="p-display">1080p display</h4>
<p>The first improvement I made was to get my RPi to display nicely on <a href="http://www.asus.com/Monitors/VS239H/">my monitor</a>. I couldn’t find any information specifically for my monitor so
I played around with changing different values of my <code class="highlighter-rouge">/boot/config.txt</code> using the <a href="http://elinux.org/RPiconfig">RPiconfig documentation</a>.</p>
<p>The NOOBS installation of Raspbian set me up with some default configurations and I ended up changing the following three sections of the config:</p>
<div class="highlighter-rouge"><pre class="highlight"><code># I uncommented the following two lines and changed the value of hdmi_mode to 16
hdmi_group=1
hdmi_mode=16
# Commented out the following four lines
#overscan_left=24
#overscan_right=24
#overscan_top=16
#overscan_bottom=16
# Changed the value to 1
disable_overscan=1
</code></pre>
</div>
<h4 id="shiny-new-toys">Shiny new toys</h4>
<p>The next steps I took involve the following three purchases I made from my local <a href="http://www.microcenter.com/site/stores/overland-park.aspx">Micro Center</a>:</p>
<ul>
<li><a href="http://www.microcenter.com/product/395710/150Mbps_wireless_N_Nano_USB_adapter">TP-LINK 150Mbps wireless N Nano USB adapter</a> Model No. TL-WN725N Ver 2.0 - I wanted to be able to move my RPi around while still keeping connectivity so
this one was a must. It was also a small pain to set up, which I will elaborate later.</li>
<li><a href="http://www.microcenter.com/product/364947/3D_Audio_Sound_Card_USB_Adapter">Sabrent 3D Audio Sound Card USB Adapter</a> - I’ve got some speech to text ideas in mind that will allow me to do some voice control type of stuff.
So far I’ve struggled to find an accurate open source and free speech to text solution. I’ve done some research on this and have seen a lot of people
using <a href="http://cmusphinx.sourceforge.net/">CMU Sphinx</a>, but my experience with it’s accuracy hasn’t been a good one. That being said, I’m sure that part of the inaccuracies stem from me not
knowing how to fine-tune it.</li>
<li><a href="http://www.microcenter.com/product/319527/4-Port_USB_20_Hub_-_Black">Mini 4 Port USB 2.0 Hub</a> - This one is mostly just a nice item to have. Mine is blue, but I couldn’t find a link to a blue one.</li>
</ul>
<p>When I got home and attempted to use my shiny and new USB devices the only one that worked right away was the hub!</p>
<p>1/3 working USB devices…</p>
<p>Of the two USB devices that didn’t work out of the box I got the wireless adapter working first. I thought this one would be easy because before
purchasing, I remember seeing it on the list of <a href="http://elinux.org/RPi_USB_Wi-Fi_Adapters">verified RPi USB Wi-Fi Adapters peripherals</a>. I was correct indeed that it was there, but there’s always
a catch. I read the line for the first version of the model number I bought and it said that it worked out of the box. Version 2 on the other hand needs
very specific drivers manually installed. The detailed description of what to do is documented very well in the <a href="http://www.raspberrypi.org/forums/viewtopic.php?p=462982">forum post by MrEngman</a>. I followed his
post to a tee and I had wireless connectivity!</p>
<p>2/3 working USB devices…</p>
<p>Fixing the sound card should have been a quick, but due to lack of knowledge of Linux and <a href="http://www.alsa-project.org/main/index.php/Main_Page">ALSA</a> it took me far too long to figure out.
The first thing I did was run <code class="highlighter-rouge">lsusb</code> in order to see if the RPi even detected my sound card, which it did. Since the usb device was recognized
I narrowed my search to things relating to ALSA. I found that by running <code class="highlighter-rouge">cat /proc/asound/cards</code> I could check the existence of a machine’s
sound cards. The sound card existed, but it wasn’t the first/default one. I then found this <a href="http://www.raspberrypi.org/forums/viewtopic.php?t=20866">forum post by ski522</a> and used the first step example to demote
the onboard sound card. I rebooted my RPi and it worked!</p>
<p>3/3 working USB devices :)</p>
<h4 id="lets-make-a-headless-pi">Let’s make a headless Pi</h4>
<p>Now that all my new toys are working, I realized it might be nice to be able to remote into my RPi and use it as a headless computer. I did some searching and
found official <a href="http://www.raspberrypi.org/documentation/remote-access/vnc/">RPi VNC docs</a>, which I paired with a <a href="http://www.penguintutor.com/linux/tightvnc">Penguin Tutor</a> tutorial. I was able to set up my RPi to start up a vncserver on boot. I then connect to it
from my Windows 7 machine. The Penguin Tutor tutorial is only important if like me you want to run the vncserver instance as a user other than <code class="highlighter-rouge">root</code>.</p>
<p>A final pro tip about beheading an RPi is that the vnc client will need the IP address of the RPi and index of the vncserver instance. I use the command <code class="highlighter-rouge">ping
raspberrypi</code> to find the IP of my RPi connected to my network. If you are only starting one vncserver the index would be 0. This means that the remote host of
my RPi looks like <code class="highlighter-rouge">123.456.7.89:0</code>.</p>
<p>With my <a href="http://i.imgur.com/NJdYV4P.jpg">headless Pi current set up</a> the only wire that needs to be plugged in is the power supply. This means that in theory I could go full wireless by using
a battery to provide power. The possibilities are endless!</p>
</content>
</entry>
<entry>
<title>Life improvements!</title>
<link href="http://edhedges.github.io/blog/2013/01/20/life-improvements"/>
<updated>2013-01-20T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2013/01/20/life-improvements</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><h4 id="tldr">TLDR</h4>
<p>This post is pretty long and if you don’t care about my story (I don’t blame you I’m a terrible writer), but want some resources to improve your overall health and fitness, go <a href="#final-thoughts">here</a>.</p>
<h4 id="why-would-i-change">Why would I change?</h4>
<p>In high school I competed in sports, music, and academics. I held myself to a pretty high standard and admittedly was very cocky and thought I was God’s gift to this world. I was in decent shape and had a pretty good diet, but I ate what I can only guess to be a metric ton of calories. When I moved out on my own my diet became that of a poor college student and my exercise consisted of occassionally playing basketball and ping pong. This led to weight gain, confidence loss, and a decrease in overall health. I continued on this path until I got with my now fiancé Katie. My confidence skyrocketed, but I continued to gain weight and my health decreased because I was in love and Katie is a phenomenal cook. Katie made and continues to make me the happiest I’ve ever been (I can’t wait to marry her in May)! This was actually detrimental to me and I noticed that my health and fitness were speeding downhill. Life went on and I had gained around 50 pounds. I was now sitting at a very fat 245ish pounds. In the summer of 2012, I decided it was time to stop hating myself and start changing.</p>
<h4 id="improvement-is-impossible-without-change">Improvement is impossible without change</h4>
<p>At first I didnt really know what I was doing so I was pretty unsuccessful, but I was determined to lose some weight. I started slowly by going on walks, jogs, and sometimes to the busy rec center at K-State. My lack of success was mainly because I wasn’t aware of some essential information about weight loss/gain. The only thing that matters for gaining or losing weight is calories in vs. calories out. This means that in order for me to lose weight, I needed to eat fewer calories than I was burning. This concept is so simple, but it is hard to execute because food is delicious and tempting. After learning this I ate much less and continued to move around more and saw a lot of progress on the scale. In a little under 2 months I had lost a around 25 pounds, felt healthier, and was ready for more. The summer of 2012 was one of the best times of my life because I had made a change for the better and learned a lot, but I was still so far away from what I am today. Looking back on it all I probably lost my weight too quickly due to a caloric deficit that was too large, but I didn’t care because I was making progress!</p>
<h4 id="continued-change-and-improvement-through-knowledge">Continued change and improvement through knowledge</h4>
<p>I was making great progress, so why would I change what I was doing? The simple answer is because of some new knowledge I had gained. Up until right before the start of my last semester of school in August, I was strictly eating less and moving more in the form of cardio outside or on an elliptical. I started doing cardio because that is what people say you are supposed to do in order to lose weight. I hate cardio. I knew that this new health and fitness me wasn’t just a fad. I had made a true lifestyle change, so I started doing some research about what else I could do to boost my weight loss. Through my research I learned healthy levels of caloric deficits and surpluses, optimal exercise, healthier foods to eat, and most importantly why only doing cardio isn’t the best thing I can do for my overall health and fitness. I soon started lifting weights, using machines and continued to do cardio as well. I was happy with my routine and diet and continued to do it until a couple weeks after school was back in to session.</p>
<h4 id="simplicity-isnt-a-bad-thing">Simplicity isn’t a bad thing</h4>
<p>Once school was in session, all the college students were back. That meant that the rec was now packed at all times. I disliked this because I felt “watched” even though I doubt anybody cared. Sharing machines takes time, and other peoples’ sweat isn’t awesome. I decided I would stop going to the rec all together and go simple. I started doing a body weight program along with cardio outside on linear trail. I soon hit the 35 pounds down mark and was loving this simple routine. The lack of complexity and time was perfect for me because I wasn’t working full time anymore, but was actually busier seeing as it was my final semester at K-State.</p>
<h4 id="different-can-mean-better">Different can mean better</h4>
<p>I continued doing my bodyweight routine as well as running outside until the weather got too cold for my liking. By the time I graduated I had lost around 50 pounds. My lowest weight has been 194 pounds. I felt stronger, quicker, and in overall better health. During the semester I started to miss weight lifting so I told myself that after graduation I would buy myself a home gym so I could get back into the weight room. I graduated from K-State on December 8th with a cumulative GPA of 3.256 and finished the semester with the highest GPA of my K-State career at 3.667. Soon after graduating I purchased 255 pounds of weight plates, a 7 foot 45 pound olympic bar, an adjustable bench, and a power rack off of <a href="http://www.amazon.com/">Amazon</a> from <a href="http://www.bodysolid.com/">Body Solid</a>. I also bought two stall mats for flooring from <a href="http://www.tractorsupply.com/">Tractor Supply</a> in Manhattan. I am completely satisfied with my investment in a homegym and wouldn’t do anything differently.</p>
<p>Here are a couple of pictures of my equipment:</p>
<ul>
<li><a href="http://i.imgur.com/knITY4y.jpg">Bar and plates</a></li>
<li><a href="http://i.imgur.com/0V7LW2W.jpg?1">Rack, bench, and stall mats</a></li>
</ul>
<h4 id="final-thoughts">Final thoughts</h4>
<p>The most important thing a lot people don’t realize is that health and fitness are not achieved by a quick or temporary fix. It takes hard work and discipline, but I believe anyone can lose/gain weight and improve themselves if they truly want to. Succeeding in health and fitness is a lifestyle and mindset change that should last as long as one lives.</p>
<p>If anyone is interested in becoming healthier and/or more fit, please check out the following resources that have been a huge help to me:</p>
<ul>
<li><a href="http://liamrosen.com/fitness.html">Beginner’s Health and Fitness Guide</a> - This read is all one needs to live a healthy and fit life.</li>
<li><a href="http://www.reddit.com/r/Fitness/wiki/faq">The fitness subreddits (/r/fitness) FAQ</a></li>
<li><a href="http://www.exrx.net/">Exercise Prescription</a></li>
<li><a href="http://examine.com/">Examine.com</a></li>
</ul>
<p>As I have stated before, the only way to gain weight is to eat more calories than you burn and the only way to lose weight is to eat less calories than you burn. That being said, I have recently started following a way of eating called Intermittent Fasting or IF. Here are some resources about IF and a stricter variation of IF called Lean Gains:</p>
<ul>
<li><a href="http://www.theiflife.com/advantages-intermittent-fasting-feeding/">Great read about IF</a></li>
<li><a href="http://examine.com/leangains-faq/">Lean Gains FAQ</a></li>
<li><a href="http://www.leangains.com/2010/04/leangains-guide.html">Lean Gains Guide</a></li>
<li><a href="http://www.1percentedge.com/ifcalc/">Lean Gains Calculator</a></li>
</ul>
<p>My weight lifting program is a slight variation/combination of three popular linear progression programs:</p>
<ul>
<li><a href="http://strengthvillain.com/forum/viewtopic.php?f=9&amp;t=89">Greyskull LP</a></li>
<li><a href="http://stronglifts.com/stronglifts-5x5-beginner-strength-training-program/">StrongLifts</a></li>
<li><a href="http://startingstrength.wikia.com/wiki/FAQ:The_Program#Three_Flavors_of_Starting_Strength">Starting Strength</a>.</li>
</ul>
<p>My goal is to weigh around 180 pounds and be around 15% body fat while increasing my levels of strength, endurance, speed, and explosiveness. I am well on my way and will see my goals met.</p>
<p>Thanks for reading!</p>
</content>
</entry>
<entry>
<title>New project idea "FormLegend"</title>
<link href="http://edhedges.github.io/blog/2012/08/06/new-project-idea-formlegend"/>
<updated>2012-08-06T00:00:00-05:00</updated>
<id>http://edhedges.github.io/blog/2012/08/06/new-project-idea-formlegend</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><h4 id="introduction-to-formlegend">Introduction to FormLegend</h4>
<p>I recently started using <a href="http://disqus.com/">disqus</a> to power the comments on my <a href="http://jekyllrb.com/">jekyll</a> powered static website. This got me thinking “What else could a static website need besides a blog and comments?”. So I compared the features I had on my Django powered site and the only difference is that I had a Contact Form. That is when I came up with the idea for FormLegend.</p>
<p>There is a project similar to what I will be working on called <a href="http://getsimpleform.com/">simpleform</a>, but I would like FormLegend to be easier to use, more customizable (validation especially), secure, and highly scalable. I am doing this as a way to learn a lot while also providing a useful web service for anyone and everyone for free!</p>
<h4 id="technology-stack">Technology Stack</h4>
<p>I plan to use many open source technologies to make FormLegend. I haven’t completely decided which ones, but I have some options before me.</p>
<p>FormLegend will work in one of two different ways. The first way is how disqus does things which is using cross-domain JavaScript communication and the other way is to use an api token or handle everything on the server side the way simpleform does things. I really like the way that disqus does things and am leaning in that direction.</p>
<p>Below are the open source libraries I am looking at.</p>
<h4 id="front-end-application-components">Front End Application Components</h4>
<ul>
<li><a href="http://haml.info/">Haml</a> or <a href="http://ruby-doc.org/stdlib-1.9.3/libdoc/erb/rdoc/ERB.html">ERB</a> Templating compiling to HTML5</li>
<li><a href="http://sass-lang.com/">Sass</a> compiling to CSS3</li>
<li><a href="http://coffeescript.org/">Coffeescript</a> (maybe) compiling to JavaScript or normal JavaScript</li>
</ul>
<p>If I do go with cross-domain JavaScript communication I will use one of two libraries:</p>
<ul>
<li><a href="https://github.com/oyvindkinsey/easyXDM">easyXDM</a> - Disqus uses this one.</li>
<li>or</li>
<li><a href="https://github.com/ternarylabs/porthole">porthole</a></li>
</ul>
<h4 id="back-end-application-components">Back End Application Components</h4>
<ul>
<li><a href="http://www.python.org/">Python</a> along with a web framework and other libraries.</li>
<li>or</li>
<li><a href="http://www.ruby-lang.org/en/">Ruby</a> along with a web framework and other libraries.</li>
</ul>
<h4 id="sql-databases">SQL Databases</h4>
<ul>
<li><a href="http://www.postgresql.org/">PostgreSQL</a></li>
<li>or</li>
<li><a href="http://www.mysql.com/">MySQL</a></li>
</ul>
<h4 id="key-value-storage-for-caching">Key Value Storage for Caching</h4>
<ul>
<li><a href="http://redis.io/">Redis</a></li>
<li>or</li>
<li><a href="http://memcached.org/">Memcached</a></li>
<li>Possibly both?</li>
</ul>
<p>I have never used any of these components before so I don’t really know what to expect. I plan on doing quite a bit of research to allow for FormLegend to be highly scalable.</p>
</content>
</entry>
<entry>
<title>Jekyll (with plugins!) hosted on GitHub Pages</title>
<link href="http://edhedges.github.io/blog/2012/07/30/jekyll-with-plugins-hosted-on-github-pages"/>
<updated>2012-07-30T00:00:00-05:00</updated>
<id>http://edhedges.github.io/blog/2012/07/30/jekyll-with-plugins-hosted-on-github-pages</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><h4 id="a-little-background">A little background</h4>
<p>A while back I was bored and burned out on a programming project I had started, so I spun up a new design for my website. I also wanted to start using a static website generator and ended up choosing <a href="http://jekyllrb.com">Jekyll</a>. I chose Jekyll so I could host it for free with <a href="http://pages.github.com/">GitHub Pages</a> as well as learn a little bit of <a href="http://www.ruby-lang.org/en/">Ruby</a> and <a href="https://github.com/Shopify/liquid">Liquid</a>.</p>
<p>Everything about Jekyll and hosting it on GitHub Pages was going very smoothly up until I wanted to use a <a href="https://github.com/mojombo/jekyll/wiki/Plugins">Jekyll Plugin</a>. Jekyll (without plugins) had almost everything I wanted except it was missing tag support for blog posts. I went with (<a href="https://github.com/pattex/jekyll-tagging">jekyll-tagging</a>) but this ended up breaking my site. I found out after reading the full GitHub Pages documentation that Jekyll plugins are not supported. I fully understand why GitHub doesn’t allow this as it could be a security issue for GitHub.</p>
<h4 id="encountering-a-small-problem">Encountering a small problem</h4>
<p>I was really set on using GitHub Pages as my host because who doesn’t like free web hosting? So I did some research on this obstacle and found that some people just generated their site and pushed the static files to GitHub and added a file named <code class="highlighter-rouge">.nojekyll</code> to the repository so GitHub pages doesn’t use Jekyll but instead <a href="https://help.github.com/articles/files-that-start-with-an-underscore-are-missing">serves the files you push to the repo</a>. My goal was to keep one repository with a master branch that contains only the static content generated by Jekyll and a dev branch that had everything Jekyll needed as well as the generated <code class="highlighter-rouge">_site</code>. I wasn’t sure if this was possible so I asked on <a href="http://stackoverflow.com/">Stack Overflow</a> if anyone knew if it could be done and if so how to do it because I was stuck.</p>
<h4 id="attempting-to-solve-the-problem">Attempting to solve the problem</h4>
<p>I received an <a href="http://stackoverflow.com/questions/11678592/is-it-possible-to-have-a-github-repo-with-two-branches-that-contain-different-di">answer to my question</a> almost immediately with exactly what I needed! I would like to thank <a href="http://stackoverflow.com/users/599922/alexandr-priymak">Alexandr Priymak</a> for helping me out and explaining his method and thinking very well. My Jekyll site with plugins is hosted on GitHub Pages thanks to him.</p>
<p>Programmers and other tech oriented people can seem unsocial and sometimes arrogant but it is people like Alexandr that remind me that communities like Stack Overflow, Reddit, and GitHub are filled with the best kind of people. These people take their time to help others out solely for the sake of helping (and possibly some internet points) and are passionate about software and technology in general.</p>
<p>I am very thankful and lucky to be part of these communities and I hope to start contributing back more as time goes on and I grow wiser.</p>
<p>Lastly on a more technical note if you would like to do what I have done and use one repository on GitHub to host a Jekyll site with plugins you can check out the Stack Overflow thread I linked above or just look at the following commands.</p>
<h4 id="problem-solved">Problem solved!</h4>
<p>These commands assume that you have a master branch and a development branch named them whatever you want. Mine are named master and dev.</p>
<p>This command creates a commit object of the development branches generated <code class="highlighter-rouge">_site</code> directory and then outputs the commits ID. We will need the ID for later so make sure that we are able to copy and paste it or at least view it.</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh"><span class="nb">echo</span> <span class="s1">'description of what we are doing'</span> | git commit-tree dev^<span class="o">{</span>tree<span class="o">}</span>:_site</code></pre></figure>
<p>Now that we have a commit object that contains only the static content in <code class="highlighter-rouge">_site</code> we want to update the master branch so that it only contains those files.</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">git update-ref refs/heads/master COMMIT_ID</code></pre></figure>
<p>So now we run a <code class="highlighter-rouge">checkout</code> on the master branch and should see only the contents of the <code class="highlighter-rouge">_site</code> directory.</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">git checkout master</code></pre></figure>
<p>This is exactly what we want but since we didn’t specify a parent for the commit we will need to push to GitHub with a force push.</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">git push -f origin master</code></pre></figure>
<p>On the other hand we can specify a parent before the push which enables us to bypass the <code class="highlighter-rouge">-f</code> option on our git push.</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh"><span class="nb">echo</span> <span class="s1">'description of what we are doing'</span> | git commit-tree dev^<span class="o">{</span>tree<span class="o">}</span>:_site -p <span class="k">$(</span>cat .git/refs/heads/master<span class="k">)</span></code></pre></figure>
<p>We don’t want to have to do all these steps every time so instead we can do everything but the push in one step like this:</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">git update-ref refs/heads/master <span class="k">$(</span><span class="nb">echo</span> <span class="s1">'Add commit message here!'</span> | git commit-tree dev^<span class="o">{</span>tree<span class="o">}</span>:_site -p <span class="k">$(</span>cat .git/refs/heads/master<span class="k">))</span></code></pre></figure>
<p>And then we just checkout the master branch and push it to GitHub. Within the next few minutes the site will be built by GitHub Pages!</p>
<p><strong><em>Update 08/07/2014</em></strong> - The above commands have worked fine for my mac, but on my Windows 7 box have had to modify the <code class="highlighter-rouge">git commit-tree dev^{tree}:_site</code>
portion of the above commands. The way I do it now looks like this: <code class="highlighter-rouge">git commit-tree dev:_site</code> so not a huge change, but I felt like I needed to document
it since I will most likely forget and come back to reference this post.</p>
<p>Here is the documentation for the commands we used with git:</p>
<ul>
<li><a href="http://www.kernel.org/pub/software/scm/git/docs/git-commit-tree.html">git commit-tree</a></li>
<li><a href="http://www.kernel.org/pub/software/scm/git/docs/git-update-ref.html">git update-ref</a></li>
<li><a href="http://www.kernel.org/pub/software/scm/git/docs/git-checkout.html">git checkout</a></li>
<li><a href="http://www.kernel.org/pub/software/scm/git/docs/git-push.html">git push</a></li>
</ul>
<p>Thanks for reading!</p>
</content>
</entry>
<entry>
<title>Macs are cooler than you think</title>
<link href="http://edhedges.github.io/blog/2012/04/04/macs-are-cooler-than-you-think"/>
<updated>2012-04-04T00:00:00-05:00</updated>
<id>http://edhedges.github.io/blog/2012/04/04/macs-are-cooler-than-you-think</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><h4 id="set-the-story">Set the story</h4>
<p>Ok, so first a little background on when I got my Mac. When I graduated in May 2008 my mom and stepdad took me to an <a href="http://store.apple.com/us">Apple Store</a> and I thought it was the coolest place ever. I walked out with a brand new Macbook Pro with 4GB of RAM and 250GB of HD space and a sweet bookbag especially made for carrying laptops. I was on top of the world, but looking back on myself and how I used my Mac back then, I’m slightly embarrased.</p>
<p>I had become the <a href="http://imgace.com/wp-content/uploads/2011/09/2000-facebook-machine.jpg">typical Mac user</a> and loved every minute (<a href="http://i3.kym-cdn.com/entries/icons/original/000/006/482/template.jpg">Oh God why?</a>). The applications I used consisted of Safari, iTunes, Microsoft Office 2008, Mail, and a little bit of iMovie. What I am trying to get at is that I could have done all the things I was doing on a <a href="http://www.microsoft.com/en-us/default.aspx">Microsoft</a> product for a much cheaper price. That didn’t matter cause I had a Mac! Don’t worry this post isn’t about bashing on Macs because I love them or bashing on people that own Macs, well not all of them :).</p>
<p>Although I started out a typical scrub Mac user I learned a more about the awesome of Macs during my summers as a technology assistant at <a href="http://www.fredoniaks.com/USD484/Home.html">Fredonia Highschool</a> and ever since then I have continued to learn and don’t plan on stopping.</p>
<h4 id="terminal">Terminal</h4>
<p>The best application that I learned about was Terminal (if you have a Mac find using Spotlight ( Space + Command ) or in /Applications/Utilities/ ( Shift + Command + U )). I first learned the simple <code class="highlighter-rouge">say</code> command. Here are some examples you should try once Terminal is open.</p>
<p>Examples</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">say Hello, World!
say I did not know Macs were so awesome.
say Eddie Hedges is a cool dude.</code></pre></figure>
<p>You can do this with any string of letters and or numbers. There is also a list of different voices you can make it say. The voices can be found in System Prefrecences under System then Speech. Under the Text to Speech tab there is a System Voice drop down list which contains the voices. Here are a few examples of how to change the default voice.</p>
<p>Examples</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">say -v Good This is the good news voice!
say -v Agnes I am Agnes.
say -v Cellos The weather could definitely be cooler yeah</code></pre></figure>
<p>While these are very simple commands there are some more complex ones that do things like allow you to play a text based game and even watch Star Wars IV right from Terminal!</p>
<p>The following command will start up a text based game so read and try typing stuff in there. Have fun! You can quit the game with ( control + C ).</p>
<p>Play a text based game</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">emacs -batch -l dunnet</code></pre></figure>
<p>The following command will start up Star Wars Episode IV in ASCII.</p>
<p>Watch Star Wars Episode IV</p>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">telnet towel.blinkenlights.nl</code></pre></figure>
<p>I realize that all of these things aren’t very productive but I use terminal daily for my programming needs. I use it to SSH, scripts, starting all kinds of services, making files and folders, opening files in <a href="http://www.sublimetext.com/2">Sublime Text 2</a> and git with GitHub. It helps me be productive and makes me feel like a leet haxor. Okay so now to the point of the post.</p>
<h4 id="what-it-all-comes-down-to">What it all comes down to…</h4>
<p>College and high school students are wanting a Mac because it is cool and it almost hurts to watch people pay over two times as much money for a computer that they don’t know how to use to its full potential, when they could just buy a cheaper one that also has an internet browser and Microsoft Office built in! I’m a supporter of Apple products but I don’t think that purchasing a Mac because it is “cool” is a smart idea. That is the only reason I wanted a Mac, but I got lucky because I am no longer “wasting” the power of my Mac and the money that was spent on it has definitely paid for itself.</p>
<p>The gist of it all is don’t buy a product that you won’t get your moneys worth out of because not everyone gets lucky like me.</p>
</content>
</entry>
<entry>
<title>Password work with Java and EzAsPy</title>
<link href="http://edhedges.github.io/blog/2012/04/02/password-work-with-java-and-ezaspy"/>
<updated>2012-04-02T00:00:00-05:00</updated>
<id>http://edhedges.github.io/blog/2012/04/02/password-work-with-java-and-ezaspy</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><h4 id="java-and-password-resets-work-related">Java and password resets (work related)</h4>
<p>If you’ve read my <a href="http://edhedges.com/blog/archives/updates-edjmicro-work-and-miscellaneous/">previous post</a> you know that I was working on my second project at work. The project consists of making a password change feature for users of the system. Security is key when it comes to people’s data and more specifically people’s money. The first phase of this project is to allow for the admin to send a user an email with a link to change their password. The url includes a parameter that has been mangled thoroughly so that it basically looks like gibberish. That parameter is the most important part of the process as we use it as a way allowing or disallowing the user to change their password. This project has been significantly more complex but it’s more exciting and I’m enjoying it so far.</p>
<h4 id="github-ezaspy-and-more">GitHub, EzAsPy, and more!</h4>
<p>I have recently started paying a whopping $7 dollars to the wonderful people over at <a href="https://github.com/">GitHub</a> to be able to have private code repositories. I was using <a href="https://bitbucket.org/">bitbucket</a> for free private repos but I like everything about GitHub better, plus I’m already using it for my public repositories and I figured I could drop $7 a month for a high quality much deserving service.</p>
<p>In my last post I didn’t have <a href="https://github.com/edhedges/edjmicro">edjmicro</a> completed but I have completed it and used it to start a personal project I am calling EzAsPy. I am still now sure exactly where I want to go with this project but I do know that it is going to be either a static website generator or a CMS type of website. I am very excited about this project because I feel like I’m really getting into some of the core features/standards of websites such as how to do registration, authentication, and main functionality of a product. I plan on open sourcing the project when I push it live.</p>
<p>Once I get registration and authentication and all the little features that go along with it the way I want I plan on creating some sort of boilerplate for getting up and running quickly with the ability to have users. Right now for registration I am using <a href="https://bitbucket.org/ubernostrum/django-registration/">django-registration</a> but and for authentication I am using the standard Django auth code but am looking at using one of the auth apps that allow for sign in with google, facebook, etc.</p>
<p>Thanks for reading!</p>
</content>
</entry>
<entry>
<title>Updates on edjmicro work and more</title>
<link href="http://edhedges.github.io/blog/2012/03/15/updates-on-edjmicro-work-and-more"/>
<updated>2012-03-15T00:00:00-05:00</updated>
<id>http://edhedges.github.io/blog/2012/03/15/updates-on-edjmicro-work-and-more</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><h4 id="why-i-havent-finished-edjmicro">Why I haven’t finished edjmicro</h4>
<p>So recently I’ve been slacking on getting any work done on <a href="https://github.com/edhedges/edjmicro">edjmicro</a>. I blame this on recently becoming addicted to the show <a href="http://www.imdb.com/title/tt0903747/">Breaking Bad</a>. I’m already on Season 4 and it is definitely giving my favorite show <a href="http://www.imdb.com/title/tt0773262/">Dexter</a> a run for its money. Once I am done with Season 4 my work should continue more frequently.</p>
<h4 id="a-little-about-edjmicro-and-future-goals">A little about edjmicro and future goals</h4>
<p>I’ve said before that I would like to build a Django based CMS for my own freelance purposes and that will be my next project. I would like the CMS to be flexible with pluggable apps just like django, while being user friendly for both the developer (me) and the user (client). I think this will enable me to spin up functional sites quickly and then focus on customizing the design for each client.</p>
<h4 id="work-success">Work success</h4>
<p>I recently completed my project at work described in my <a href="http://edhedges.com/blog/archives/java-web-development-and-also-some-django/">previous post</a> and have been assigned a new project. The task is to create a “reset password” feature that sends an email to the user with an encrypted link. The link will expire in 24 hours. Clicking the link enables the user to reset their password and move on with their experience. I have started the project and I think it will be less time consuming but more complex (security issues) and I look forward to the challenge!</p>
<p>Thanks for reading!</p>
</content>
</entry>
<entry>
<title>Java and Django Development</title>
<link href="http://edhedges.github.io/blog/2012/03/12/java-development-and-some-django"/>
<updated>2012-03-12T00:00:00-05:00</updated>
<id>http://edhedges.github.io/blog/2012/03/12/java-development-and-some-django</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>Last week I found <a href="http://softwaremaniacs.org/blog/2011/01/07/django-micro-framework/en/">this post</a> while browsing the <a href="http://www.reddit.com/r/python">Python subreddit</a>. I was intrigued by the idea of making my django projects super light weight and so I have been working on a boilerplate for django as a “micro framework”. My progress as well as the source can be found <a href="https://github.com/edhedges/edjmicro">here</a>. After this project I plan on building a lightweight Content Management System and hope it doesn’t need to be backed by a database.</p>
<h4 id="work-related-ventures">Work related ventures</h4>
<p>The first task I was assigned at my job was to write some java code that allows an admin user of the system to find duplicate users and then be able to merge those users. This task allowed me to hit the ground running and really learn a lot about the <a href="http://www.javaserverfaces.org/">JSF Framework</a> and the <a href="http://www.jboss.org/richfaces">RichFaces Project</a>. I also learned more about MySQL and actually writing SQL. Having to do this has really made me thankful that django has an Object Relational Mapper with a rich <a href="https://docs.djangoproject.com/en/dev/topics/db/queries/">API</a>, because this makes all the database work stupidly simple.</p>
<p>Throughout the project I wrote xml, jQuery, .jsp, SQL, and of course Java. All of my code is contained within 5 files. One thing I hope to improve while working on the web system is what the urls look like. Coming from django I am disappointed there isn’t a simple way to make urls look a little more elegant. For example all the urls have a .jsf extension but with django you can write your patterns and make pretty urls that are readable, dynamic, and don’t contain file extensions (unless for some sick reason you actually write a regular expression to match something like afile.php, but seriously who would do that?).</p>
<p>Overall I am really enjoying the job and can’t wait to get my hands on my next project.</p>
<p>Thanks for reading!</p>
</content>
</entry>
<entry>
<title>My setup</title>
<link href="http://edhedges.github.io/blog/2012/03/05/what-is-my-setup"/>
<updated>2012-03-05T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/03/05/what-is-my-setup</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>In previous posts I have talked quite a bit about what types of programming I do and other nerdy stuff but in this post I would like to recognize <strong>ALL</strong> the tools I use daily for programming purposes as well as just fun. I think the best way to do this would be in list form, so here goes:</p>
<h4 id="hardware">Hardware</h4>
<ul>
<li><a href="http://www.apple.com/">MacBook Pro running Mac OS X 10.6.8</a> - I have had this laptop since the summer of 2008. I got it as a graduation present and still today it is a wonderful machine. It has 2.5GHz Intel Core 2 Duo processing power and 4 GB of Ram. Overall a great machine and I hope that when I get a new mac I am not disappointed because this one has spoiled me.</li>
</ul>
<h4 id="software">Software</h4>
<ul>
<li><a href="https://www.google.com/chrome">Google Chrome</a> - This is my browser of choice. If you like applications that are easy to use, fast, and powerful then Google Chrome should be your browser. The first time I tried chrome I immediately knew I wasn’t ever going to be happy with another browser. I highly recommend this not only for web development/design but for general all purpose web browsing. Also IE sucks.</li>
<li><a href="http://store.apple.com/us/browse/home/shop_mac/software">Apple Mail</a> - I have been using Apple’s built in email client since before I had my laptop. There isn’t a better email client out there in my opinion. I use it to manage my gmail, k-state, and new ACEware email accounts. I think mac users will agree that apple mail beats out any other mail client be it a desktop or web interface.</li>
<li><a href="http://www.sublimetext.com/2">Sublime Text 2</a> - This is the newest addition to my toolset and it is completely amazing. Sublime Text 2 is a beautiful and powerful text editor. I have used <a href="">Notepad++</a>, <a href="">TextWrangler</a>, and many other text editors but none come close to Sublime. I purchased it for $60 and it has been a wonderful investment.</li>
<li><a href="http://guides.macrumors.com/Terminal">Terminal</a> - This is the coolest application on the Mac hands down. Terminal is a command line application allowing access to be able to control the UNIX base. In high school I liked using terminal for small things such as typing:</li>
</ul>
<figure class="highlight"><pre><code class="language-sh" data-lang="sh">say I am a robot</code></pre></figure>
<p>This command would signal the computer to output the phrase “I am a robot” in an audio version. It hasn’t been until more recently that I have used it for more productive things such as ssh, git and github/bitbucket, fabric and in a more broad sense executing python code. I could go on and on about more specific things I do with terminal but I’ll save that for a future post.
* <a href="http://filezilla-project.org/">FileZilla</a> - Another application that has recently grown on me is FileZilla. FileZilla is an application that allows me to do ftp. I have used WinSCP for Windows and Cyberduck for Mac but when I found FileZilla I haven’t looked back. FileZilla is free, cross-platform, user friendly, and powerful.
* <a href="http://www.eclipse.org/">Eclipse</a> - This application is an integrated development environment mainly used for Java but can be used with other languages. I used eclipse my first year at K-State in the intro programming class when I learned Java. I have picked it back up to use at my new job at <a href="http://aceware.com/">ACEware</a>. I am using it for Java web development using the jsf framework and richfaces.</p>
<h4 id="web-resources">Web Resources</h4>
<ul>
<li><a href="https://www.google.com/">Google</a> - Google is my go to resource for everything. I honestly don’t know what I would do without it. Why read a book when you can just google it right?</li>
<li><a href="https://github.com/">github</a> - A place where coders can collaborate and store their project by using git.</li>
<li><a href="https://bitbucket.org/">bitbucket</a> - Similar to github but not as pretty in my opinion. I use bitbuckets free private repos for deployment since I don’t want people to be able to see if I have sensitive information in my live code.</li>
<li><a href="http://djangoproject.com/">Django</a> - This is my main resource for making django powered sites and applications. Django rocks!</li>
<li><a href="http://dillinger.io/">Dillinger</a> - An interactive html5 and markdown editor for the web. I write my blogs and README.md files with Dillinger.</li>
<li><a href="http://www.reddit.com/">Reddit</a> - I use reddit for pleasure as well as to stay updated on what other web developers and web designers are doing. This reddit <a href="http://www.reddit.com/r/webdev+python+django+web_design+webdesign">LINK</a> is one of my favorites to browse for learning purposes.</li>
</ul>
<p>Resources are great! I highly recommend everything on the list. If there are any questions about any of the information make sure to comment or <a href="http://edhedges.com/contact/">contact me</a>.</p>
<p>Thanks for reading!</p>
</content>
</entry>
<entry>
<title>Comments are live and more stuff</title>
<link href="http://edhedges.github.io/blog/2012/02/29/comments-are-live-and-more-stuff"/>
<updated>2012-02-29T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/02/29/comments-are-live-and-more-stuff</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>I have updated my blog to allow for anonymous comments using the <a href="https://docs.djangoproject.com/en/dev/ref/contrib/comments/">django comments framework</a>!</p>
<p>I chose to go anonymous because as it says in the <a href="http://www.python.org/dev/peps/pep-0020/">Zen of Python</a> that <code class="highlighter-rouge">Simple is better than complex.</code></p>
<p>The jQuery hack hasn’t been implemented yet but will be soon. The only problem I have is that since I am using the django comments my sites navigation styles I am using don’t apply when there is an error with the comment form. Other than that I am satisfied with the simple comments that are now live with my blog.</p>
<p>The next update for comments will be to allow for <a href="http://daringfireball.net/projects/markdown/">markdown</a> because its awesome!</p>
<p>As I mentioned in a <a href="http://edhedges.com/blog/archives/next-items-my-agenda/">previous post</a> I wanted to implement markdown syntax to create blog posts and I did!</p>
<p>My custom admin form for my blog is just a simple form that reads markdown and converts it to look great once posted but it isn’t the best for actually writing the post. That is why I have been using <a href="http://dillinger.io/">Dillinger</a>. The real time markdown and html5 editing is amazing with a great looking interface. In my opinion there isn’t a better free online editor.</p>
<p>List view of next items on my agenda:</p>
<ul>
<li>Make that quick jquery/style change to keep uniformity (because uniformity rocks)</li>
<li>Adding markdown to the blog comments</li>
<li>Hopefully pick up some freelance projects along the way</li>
<li>Implement the ability to add media to my blog app</li>
<li>In march I will be overhauling my <a href="https://github.com/edhedges/eds-djangoplate">django boilerplate</a></li>
</ul>
<p>That wraps it up for me thanks for reading!</p>
</content>
</entry>
<entry>
<title>Blog changes including comments</title>
<link href="http://edhedges.github.io/blog/2012/02/27/blog-changes-with-comments"/>
<updated>2012-02-27T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/02/27/blog-changes-with-comments</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>So I said I was going to be adding comments and I decided to just go for anonymous comments because simpler is better.</p>
<p>In my opinion there is no reason for the user to have to sign in to comment on my blog they can just comment and move on or if they really need to speak to me privately and not in the public eye they can get in touch via the contact form.</p>
<p>I need to do a bit more testing and maybe a little bit of jquery hacking to keep things uniform since I am using django’s built in comments I don’t get to delegate the views without doing extra work that doesn’t need to be done. The problem is that when a user presses the <code class="highlighter-rouge">Add Comment</code> button they are redirected to a django page with my css/html but I can’t pass the template a variable so that my site knows where it is at.</p>
<p>By doing some quick jQuery I should be able to add the one style I need to in order to keep my site uniform. Right before I push it live though I will make sure that all my code is valid from the <a href="http://validator.w3.org/">W3C Validation Service</a>.</p>
</content>
</entry>
<entry>
<title>Next items on my agenda</title>
<link href="http://edhedges.github.io/blog/2012/02/24/next-items-on-my-agenda"/>
<updated>2012-02-24T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/02/24/next-items-on-my-agenda</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>As for right now I am writing my posts in simple html but I would like
to start using <a href="http://daringfireball.net/projects/markdown/">markdown</a> so that will be my next update to the blog
app. After that is complete I have one more update I want to put on and
that is to allow comments possibly using <a href="http://openid.net/">OpenID</a>. Lastly I plan on
building an API for my blog.</p>
<p>After that I should be done with the functionality I want. I plan on
then doing free lance web design and development as well as a couple web
app ideas I have in mind. Overall I just want to immerse myself more
into <a href="http://python.org/">python</a>, <a href="https://www.djangoproject.com/">django</a>, and the web in general.</p>
</content>
</entry>
<entry>
<title>Back with a new design</title>
<link href="http://edhedges.github.io/blog/2012/02/21/i-am-back-with-a-new-design"/>
<updated>2012-02-21T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/02/21/i-am-back-with-a-new-design</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>Well I have been hard at work in the design department because I wanted
my site to be responsive and look good on any browser size. I have also
been working on my custom blog admin and the thing I am most proud of is
that I have built a wonderful django boilerplate.</p>
<p>My boilerplate is on github and can be found <a href="https://github.com/edhedges/eds-djangoplate">here</a>. I built the
boilerplate because I wanted a standard setup for all my future
projects. The boilerplate will not only help me speed up my development
but will make integrating outside code simple as well as making
deployment a simple task thanks to <a href="http://docs.fabfile.org/en/1.4.0/index.html">fabric</a>.</p>
<p>Below I will show you a fab function that runs when I deploy to
production.</p>
<figure class="highlight"><pre><code class="language-py" data-lang="py"> <span class="k">def</span> <span class="nf">deploy</span><span class="p">():</span>
<span class="s">"""
Deploys the django project.
"""</span>
<span class="n">run</span><span class="p">(</span><span class="s">'mkproject </span><span class="si">%</span><span class="s">s'</span> <span class="o">%</span> <span class="n">PROJECT_ID</span><span class="p">)</span>
<span class="k">with</span> <span class="n">cd</span><span class="p">(</span><span class="n">env</span><span class="o">.</span><span class="n">current_project_dir</span><span class="p">):</span>
<span class="n">run</span><span class="p">(</span><span class="s">'git init'</span><span class="p">)</span>
<span class="n">run</span><span class="p">(</span><span class="s">'git pull https://[email protected]/edhedges/</span><span class="si">%</span><span class="s">s.git master'</span> <span class="o">%</span> <span class="n">PROJECT_ID</span><span class="p">)</span>
<span class="n">run</span><span class="p">(</span><span class="s">'pip-2.7 install -r conf/requirements.txt'</span><span class="p">)</span>
<span class="n">run</span><span class="p">(</span><span class="s">'python2.7 manage.py new_secret'</span><span class="p">)</span>
<span class="n">run</span><span class="p">(</span><span class="s">'python2.7 manage.py syncdb'</span><span class="p">)</span>
<span class="n">run</span><span class="p">(</span><span class="s">'python2.7 manage.py migrate'</span><span class="p">)</span>
<span class="n">run</span><span class="p">(</span><span class="s">'mv static/* </span><span class="si">%</span><span class="s">s'</span> <span class="o">%</span> <span class="n">env</span><span class="o">.</span><span class="n">static_dir</span><span class="p">)</span>
<span class="k">with</span> <span class="n">cd</span><span class="p">(</span><span class="n">env</span><span class="o">.</span><span class="n">static_dir</span><span class="p">):</span>
<span class="n">run</span><span class="p">(</span><span class="s">'rm -rf admin'</span><span class="p">)</span>
<span class="n">replace_httpdconf</span><span class="p">()</span></code></pre></figure>
<p>This command I can run by typing ‘fab deploy’ makes a project directory
and a virtual environment, then it initializes a git repo in the project
folder and pulls my project in. After that is done it install all
dependencies using pip and it moves the static folder into my static
url. After all that is done it replaces the default httpd.conf file with
one tailored to my project and restarts apache.</p>
<p>Sta tuned for more django/python awesome!</p>
</content>
</entry>
<entry>
<title>Sidetracked</title>
<link href="http://edhedges.github.io/blog/2012/02/11/sidetracked"/>
<updated>2012-02-11T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/02/11/sidetracked</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>So… I have recently gotten sidetracked on my blog work because I have
been working on a django boilerplate for myself. The goal of my
boilerplate is to be as simple/customizable as I need it to be. Another
main goal for this boilerplate is that it should easily be pushed my
production server hosted by <a href="http://www.webfaction.com/">WebFaction</a>.</p>
<p>Once I am done with the boilerplate and have tested and streamlined my
development process I will be finishing up some blog changes as well as
porting my current site to the boilerplate.</p>
<p>My boilerplate will live on my <a href="https://github.com/edhedges">github profile</a>.</p>
</content>
</entry>
<entry>
<title>New job and other updates</title>
<link href="http://edhedges.github.io/blog/2012/02/08/new-job-and-other-updates"/>
<updated>2012-02-08T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/02/08/new-job-and-other-updates</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>I have accepted a job at <a href="http://www.aceware.com/">ACEware</a>. I will be working on a web
application using <a href="http://www.java.com/en/">java</a> and <a href="http://www.eclipse.org/">Eclipse</a>. I am pretty excited to start
working for ACEware and expanding my skills in the area of web
development.</p>
<h4 id="updates-on-personal-projects">Updates on personal projects:</h4>
<p>I have started getting a custom admin for edBlog. I currently have the
ability to make a post and most of the basic admin functionality written
I just need to implement a way to automatically “urlify” my titles. I
haven’t implemented the new features like uploading a picture, the
ability to comment, or using markdown but that will be coming soon.</p>
</content>
</entry>
<entry>
<title>Katie's website and other stuff</title>
<link href="http://edhedges.github.io/blog/2012/02/02/katies-website-and-other-stuff"/>
<updated>2012-02-02T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/02/02/katies-website-and-other-stuff</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>I just want to give a shout out to my fiance <a href="http://kaitlynelise.info/Kaitlyn_Phillips/Welcome.html">Katie Phillips</a> for
building a website in <a href="http://www.apple.com/ilife/iweb/">iWeb</a>!</p>
<p>I had told her before that I would build her a website but she didn’t
think she needed one but this year she is taking a class about using
technology in the classroom and one of her assignment was to make a
site. I am proud of her because to be honest she isn’t that tech savvy.</p>
<h4 id="now-on-to-some-news-about-what-i-will-be-working-on-next">Now on to some news about what I will be working on next.</h4>
<p>I plan on making my blogging application great and here is a list of
some of the things I want to add to it.</p>
<ul>
<li>A custom admin because I am using the django admin at the moment and
even though its awesome if I want to distribute this app and have
others use it their should be a custom admin.</li>
<li>An ability to leave comments on a post. I haven’t decided whether to
make them anonymous or have users sign up for a simple account yet.</li>
<li>The ability to upload pictures to make it look more appealing.</li>
<li>I currently make my posts by writing html that goes into my page
from the admin but I want to start using <a href="http://en.wikipedia.org/wiki/Markdown">markdown</a>. I am really
excited for this part because I found an awesome online editor
called <a href="http://dillinger.io/">Dillinger</a>.</li>
</ul>
<p>Lastly I know there are tons of blogging apps out there in many
languages but I am building this app because I want it to be the
simplest (for users) as well as learn many things along the way.</p>
<p>Thanks for reading!</p>
</content>
</entry>
<entry>
<title>Django from development to production</title>
<link href="http://edhedges.github.io/blog/2012/02/01/django-from-development-to-production"/>
<updated>2012-02-01T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/02/01/django-from-development-to-production</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>In this blog I will briefly describe my process of taking my local development work and putting it into production which is what I did with this site and its features.</p>
<p>For my development process I am using the simple local server that django/python provides you by running:</p>
<figure class="highlight"><pre><code class="language-pycon" data-lang="pycon">python manage.py runserver</code></pre></figure>
<p>If you are a more experienced dev then there are things such as <a href="http://pypi.python.org/pypi/virtualenv">virtualenv</a> and <a href="http://docs.fabfile.org/en/1.3.4/index.html">fabric</a> but I kept it simple for this first large project.</p>
<p>I use <a href="http://www.webfaction.com/">webfaction</a> as my hosting service and love them. The admin side allows for easy installation of django and MySQL database creation from the browser! If you are looking into doing development I would definitely check out webfaction.</p>
<p>Now getting back on track below will be a list of things that will be different for production in the settings.py file from your local project.</p>
<ul>
<li>Set DEBUG and TEMPLATE_DEBUG = False</li>
<li>Make sure to change your DATABASES if you plan on not using sqlite3</li>
<li>Lastly make sure your static, media, and template settings are changed to match your production file layout.</li>
</ul>
<p>I think the first two are pretty self explanatory and well documented in the django docs but the third gave me a bit of a headache. During development django will get static files from within your project but when DEBUG = False (<a href="https://docs.djangoproject.com/en/dev/ref/settings/#std:setting-DEBUG">which it should be when its in production</a>) django will not serve those static files. In webfaction I have made a static application which lives at a specific URL and that will serve all my css, js, and other static files.
For a more in depth look at deploying django check out the <a href="http://www.djangobook.com/en/2.0/chapter12/">django book chapter 12</a>. It is a bit old but got me through.</p>
<p>That sums it up thanks for reading!</p>
</content>
</entry>
<entry>
<title>Welcome to edBlog!</title>
<link href="http://edhedges.github.io/blog/2012/01/31/welcome-to-edblog"/>
<updated>2012-01-31T00:00:00-06:00</updated>
<id>http://edhedges.github.io/blog/2012/01/31/welcome-to-edblog</id>
<author>
<name>Eddie Hedges</name>
<uri>http://edhedges.github.io</uri>
</author>
<content type="html"><p>Welcome to edBlog! This is my first of many posts I will be making here on edBlog. I plan to blog about my life, code, web stuff, and basically anything I find interesting.</p>
<p>edBlog is a simple blogging application I built for my own use. It is built using the django framework which is awesome by the way. Django is a web framework built in python. If you are interested go ahead and read more about it <a href="https://www.djangoproject.com/">here</a>.</p>
<p>I have recently gotten into web development in python/django and have been loving it. I am planning writing some useful little scripts and also developing some slightly larger applications for the web. Stay tuned here for updates and also don’t forget to “fork” me over at <a href="https://github.com/edhedges">my github</a>.</p>
<p>I think that is all for now thanks for reading.</p>
</content>
</entry>
</feed>