Cutting Back

Today I ran through my bank statements, and realized that I was spending around $80/month on cigarettes. Normally this number wouldn’t phase me for any other commodity, save for the fact that cigarettes are hardly essential, and definitely not beneficial. It’s been an on-again off-again idea of mine to remove smoking from my daily activities. The main difficulty has been in finding enjoyable activities to offset the cravings.

Yes, I can drink water, go for walks, read books, and exercise, but truly, these things are white devils.

So, I tabulated the number of cigarettes I was consuming monthly, and arrived at 200.

Using the information on the side of the pack, the following values are the minimum and maximum amounts of poison I am consuming (per month):

Tar
minimum:
2.2 grams
maximum: 5.2 grams

Nicotene
minimum:
0.2 grams
maximum: 0.24 grams

Carbon Monoxide
minimum:
2.8 grams
maximum: 5.6 grams

Formaldehyde
minimum:
0.0114 grams
maximum: 0.028 grams

Hydrogen Cyanide
minimum:
0.02 grams
maximum: 0.044 grams

Benzene
minimum:
0.0056 grams
maximum: 0.0134 grams

The most upsetting values are tar and carbon monoxide. Up to 5.2 grams of road covering for my lungs in a month? A guaranteed 2.2 grams at the least? Sadly, these values don’t motivate me to immeadiately cast the pack out the window, however I feel like striking a deal midway.

Playing so much guitar, I’ve come to appreciate the value of incremental progress.

Thusly, if I smoke ~6.6 cigarettes/day,  I’m willing to call it 5/day, and next month, hopefully only 4/day. And so on. By the time I’m down to 1/day, I may end up skipping days, and my exercise routine will be in full swing.

I suspect the cold turkey faction are a bunch of lunatics. I’ve tried it so many times, it causes me to recall a wonderful quote by Mark Twain:

“It’s easy to quit smoking. I’ve done it hundreds of times.”

and with that, I’m satisfied.

Things I love about CakePHP

I’ve been developing with CakePHP for about 2 weeks now. Figured I’d post 10 reasons I love CakePHP:

  1. Model-View-Controller Architecture
    After hard-coding a million failed dynamic websites, it was refreshing to learn about MVC programming. Rather than fretting about data, presentation, and logic at the same time, Cake separates these into individual parts. Specify your data, implement the logic, create a view. A chimp could do it.
  2. Pages Controller for static content (with support for hierarchies)
    In all of this dynamic insanity, it’s nice to have a pre-coded controller for managing static pages. Every site has static pages (about, contact, etc.) The pages controller allows for these parts to be added simply to the rest of your more complex project.
  3. Easy as pie (or cake) Authorization component
    While coding authentication modules may not be the worst thing one could be tasked with, CakePHP makes it irrelivant. In about 10 lines of code you can have a simple login system up and running, blocking the outside world from whatever you don’t want them to see. By default the Auth component blocks all methods in a controller unless you explicitly allow them. This makes it less likely for methods specified later on the be accidentally open to the public (unless of course you want that).
  4. Router for clean, tidy, and powerful URL handling
    Cake has a rather straightforward URL convention as it is, but if you don’t like it, Router allows you to change it however you like.  It allows you to link specific urls or patterns to specific controllers. The possibilities with this are limitless, and I know I’ve barely scraped the capability of this module. Sure beats tearing your hair out over .htaccess files all day.
  5. Components, Behaviours, Layouts, and Helpers
    Components share logic between controllers. Behaviours add functionality to models. Layouts allow re-use of code in views. Helpers just help with everything from forming links to creating forms (and more).
  6. Clean Conventions for Everything
    Cake’s power is in its strict conventions. A lot of overhead is saved by enforcing a strict set of rules regarding how you use it. This allows the framework to make a large number of assumptions about your application, saving you the time it takes to explicitly specify such things. It can be frustrating at first, but as you pick each bug out of your code, you become more familiar with these guidelines in an intuitive way.
  7. Dead Simple Installation
    Copy, Paste, open up 2 text files,  set up your database connection, and change the security salt value (I believe it’s used in hashes). You’re rolling (assuming Apache has all the needed modules running, mod_rewrite being the key to Cake’s awesome URL magic).
  8. Admin Routing
    So you have say a song controller, and an edit method. We access it at http://%cakedomain%/songs/edit/.  For normal authenticated users, this will display the edit page. Say you had additional parameters that couldn’t be edited by standard users though. Enter admin routing. Now at http://%cakedomain%/admin/songs/edit/, we will be forwarded to the admin_edit() method of the songs controller. No need to code any fancy access control or custom control panels (although you could rather simply, or just use Routing). Very sexy.
  9. The all-mighty beforeFilter() function
    Want to run a set of logic before each controller method is called? Done. Useful for allowing certain pages without authorization in conjunction with the Auth module.
  10. The webroot folder
    Keep all your CSS, Images, and JS in one location. Easily reference all these files without getting tangled up in hideous piles of path. One advantage to this is that your CSS files can be static, as the path to the respective image resources is constant.

I’m enjoying this thoroughly.

Cyclic Meritocracy

So, we’re living in a meritocracy

Supposedly the distribution of wealth in our society is based on the merit of individual efforts. Those who are skilled and deserving are then thought to have earned the bounty they have. The converse is that those without assets are likely to be undeserving of any monetary wealth. Contrast this with the social system a few hundred years ago. Back then the distribution of money and power was based on a religious hierarchy. A peasant would not question his poverty, and a nobleman would give no thought to his excess. It was God’s plan.

It would seem, then, that our new explanation for the wealth gap is merit. Arguably, merit is much more fickle than any deity could have been.

One small problem

If you haven’t noticed, wealth only begets more wealth. Merit isn’t so much a thing in itself as it is a rather complex interaction. Merit becomes further questionable when you take into account the complex (read, bullshit) economics that govern it.

The first groups to go out and amass currency beyond any reasonable need have set themselves ahead. Instead of considering a course of action, and then imagining how to go about sustaining it, they simply flick their wrist and the world bends. For proponents of social darwinism, this is no more than a logical extension of evolution. The only problem with such a view is that evolution occurs naturally. Social darwinism is to nature as genetic engineering is to evolution. If we’ve learned anything from genetic engineering, it could be that we ought not toy around with that we don’t fully understand. Such conservative views are a little too limiting. Thusly, we have all sorts of Ethics to allow us a chance to tinker where it won’t hurt, and stay away from areas that would be more obviously detrimental.

So if communism isn’t going to cut it, what will?

Why not make it more like a game

I love games. If I’ve found anything in life, it’s that everything is more or less an insignificant game. This is how I arrived at the idea I like to call Cyclic Meritocracy. It can’t be refuted that merit (in itself) is a useful discriminator. At the same time, its practical implementation leaves some things a little unbalanced.

So, take all the money in the world, let it run about freely on a merit basis for a given period of time, and at the end of the period use some kind of redistribution scheme to offset any imbalances brought on by the imperfection of merit’s implementation. It’s important to note that I’m not discussing material wealth when I say redistribution. One could do this, but I have it in my head that a redistribution of monetary wealth would be enough to create an interesting effect.

Many argue that capitalism’s greatest strength is its power as an incentive. The incentive is to burn hard once, and then never lift your finger again. Although not all involved in the system reach such a level of lethargy, it is the end goal. I could think of no greater motivation than to have me feet swept out from under me after having made myself nice and comfortable. In such a system, those who innately desire to succeed and propel themselves forward would take the “blow” of redistribution with grace, and with a love of challenge.

Large groups containing vast amounts of capital are inherently wasteful. When they are effecient, they consider the wrong factors (“let’s fire half of our workforce instead of actually making a sustainable product”). In a monoculture of big brands, there is an unmentioned desire for the advantages of a more diverse and dynamic economic horizon. In such a retooled system, great names would be remembered and revered for their individual contributions to the course of human evolution, and not for the hundreds of digits next to their name. People would no longer aspire to comfortable complacency as they would to meaningful achievement.

Not in a hundred years

Fair enough, but the gears are turning. Recall there was a time when no peasant would imagine that the future could hold a system where anyone was capable of vast riches.

Changing the default swatch in Illustrator CS4

The Motivation

Fucking hideous, no?

Fucking hideous, no?

Don’t know about you, but I’m anal when it comes to efficiency. Choosing a colour palette is an essential part of creating attractive artwork. All of this might be a little easier if your senses weren’t offended by the canned swatch that comes with Adobe Illustrator CS4 every time you start a new piece. This mini tutorial should hopefully help you rid yourself of this beast and save yourself the carpal tunnel syndrome of clearing out the default swatch every time you want to just File-New and Go.

The [arduous] Process

You could spend an entire evening going through all the imaginable template settings in the main application. Some people might just settle for loading a template in a browse window for every new document. To me, that’s too much work (hopefully you’re as lazy as me).

The default document settings are stored in a .AI file in the bowels of your harddrive. Open up Explorer and point yourself to:

C:\Documents and Settings\yourUserNameHere\Application Data\Adobe\Adobe Illustrator CS4 Settings\en_GB\New Document Profiles\

Here you will find 6 files:

  • Basic CMYK.ai
  • Basic RGB.ai
  • Mobile and Devices.ai
  • Print.ai
  • Video and Film.ai
  • Web.ai

Each of these correspond to options in the main window that greets you when you open the program.

Familiar territory

Familiar territory

Personally, I do a lot of digital work, so I only use the Web template (although the following tweak can be applied to any of the files mentioned above, depending on your preferences).

If you open Web.ai and open up the swatch panel, you’ll be greeted by the usual hideous clusterf*ck you’ve come to despise. On the top right corner of the panel there’s a small icon that looks like a down arrow with 4 horizontal lines beside it. Click this and then click Select All Unused. Now click on the trash can at the bottom right corner of the panel. There may be a few colours left over, you should only have 4: None (red stripe), Registration (crosshair), Black, and White. If any other colours remain, simply select them, and hit the trash can. When you’re done you should see something like:

this! Much better.

this! Much better.

Now just save Web.ai, close the file, restart Illustrator, and you’re good to go. Remember that this process can be easily applied to any of the other template options on the splash screen. Next time you create a Web Document, your swatch should be nice and clean :)

The Moral of the Story

I think that settings like the default swatch are in everyone’s interest. I was surprised to find that this process was so convoluted, and undocumented. Remember this next time you set out to write a market-stomping vector illustration tool of your own :)

Happy doodling.


graphics, and reading

Just finished up Rant by Chuck Palahniuk. Good reading, if not a bit convoluted.

Also, started a deviantArt account under the StkMtd moniker. Below are my first two uploads:

I christen ye mine blog

When I woke up this morning, I was suddenly inspired to spend my time doing more awesome things.

On the agenda:

  • Install Linux
  • Start learning C++ like a mad cunt (so I can one day write my own sample-precise DSP routines)
  • Organize my production environment and make sexier tunes (they’re already rather sexy)
  • Smoke cigarettes

That’s all for now, but I leave you with some wonderful tune-age. This is the latest and greatest (insofar as complete works go). Indulge.



Follow

Get every new post delivered to your Inbox.