Men’s rights activists: Stop.

Stop saying you’re not feminists, you are. Unless you think women aren’t as good as men, or that they don’t deserve the same chances, you believe in the premise of feminism. Saying you’re not feminists makes you sound like idiots, liars or misogynists.

Stop saying you’re “egalitarian” as if it’s mutually exclusive with feminism, that’s ridiculous. Women’s rights is an obvious and perpetual facet of any sensible mission to make all people equal. Your toxic stubbornness to accept multiple labels is literally making “equality” a bad word. This is why we can’t have nice things.

Stop seeking out feminists that make you upset. You don’t need to agree with them and they definitely don’t need to prove anything to you. You invented the “feminazi” then proceeded to breed them with your narcissistic, hateful and inexplicably violent comments. If you can’t find respect and empathy for someone’s views leave them alone, you’ll feel better and they won’t hate us all so much.

Most of all, stop blaming women for your problems. Stop deluding yourselves that you aren’t the luckiest humans in history to even be having this conversation. Yes, men are also bullied, stereotyped and raped, no one is saying they aren’t. We can all work together on these issues that affect everyone, but only if you accept responsibility for the completely unequal situation we find ourselves in.

Try making something out of love instead of hate. Try speaking from a position of empathy rather than conviction. Try assuming the best from feminists, then watch how easy it becomes to find fair, “reasonable” women that don’t mind talking to you.

P.S. It’s time to learn what “cisgender” means.

Star Wars Day Meditations: Jedi Code v. Sith Code

The Jedi Code from a comic book

MAY THE FOURTH BE WITH YOU

This Star Wars day consider studying some Jedi philosophy along with the memes. The natural starting point is the Jedi Code, a short mantra that was the foundation of Jedi emotional control and a key element of the Knighthood for thousands of years.

The Jedi Code

There is no emotion, there is peace.
There is no ignorance, there is knowledge.
There is no passion, there is serenity.
(There is no chaos, there is harmony.)(*)
There is no death, there is the Force.
The Jedi Code (Based on the meditations of Odan-Urr)

For bonus points dig into the Sith code to consider what distinguishes them and which you agree with more.

The Sith Code

Peace is a lie, there is only passion.
Through passion, I gain strength.
Through strength, I gain power.
Through power, I gain victory.
Through victory, my chains are broken.
The Force shall free me.
The Sith Code (as written by Sorzus Syn and taught by Darth Bane)

Book recommendations for true Star Wars nerds (both have excellent Audible.com versions):

Darth Bane Trilogy – The story of the founder of the modern “rule of two” Sith tradition who killed all the other Sith lords ~1000 years before Anakin Skywalker was born.

Darth Plagueis – The shocking and fascinating life of Darth Sidious’ own Sith master, a high-powered banker in the Old Republic who used his position in conjunction with Palpatine’s to fund the destabilizing “war” with the separatists that ultimately toppled the Republic.

Both of these books (well all 4 since the Bane books are a trilogy) are centered on Sith Lords rather than Jedi, but they are still probably the best way to understand what motivates the Jedi and their religion. Jedi define themselves in relation to the Sith just as Christians define God in relation to Satan, and it seems that the Sith are more willing to think honestly and frankly about the true nature of the force than the Jedi are.

Read books about Jedi for action, heroism and blind faith. Read books about the Sith for ethical enquiry, contemplation and historical analysis of the Republic and it’s super-powered rulers.

Mourning the Canadian Census

In the early new millennium Canadian history was being erased by never having been recorded. Against a unified opposition the dominant Conservative party halted the mandatory census, citing privacy concerns.

The decades-long civic research project was recast as optional and no data was collected to match previous census results. It took years for the effects to be felt because the timeframe was so long, but researchers started missing the data, relying on out of date results from past censuses.

We will never get back these years of knowledge even if the census is rescued, meaning we can never accurately assess the effects of Conservative policy on Canadians.

The Harper legacy will be a black hole.

Al Jazeera: What happened when Canada stopped counting its numbers

Voices-Voix: Statistics Canada (mandatory long-form census)

The easiest couple costume if you don’t mind being hit on by surprising people

For Halloween 2013 Sarah and I were going to go as our cats, but after being reminded about this great photo project with portraits of couples wearing each other’s clothes we decided to go as each other instead.

Animated gif of Jer and Sarah with their own clothes, then each other's clothes on.

SomaFM is great music to code to

/**
 * @see http://somafm.com/
 */
if (is_playing('somafm', array('Beat Blender', 'Digitalis', 'Cliqhop')))
	$productivity++;

When it comes to musical accompaniment for coding or really any work that requires focus, I can never find anything better than SomaFM, a network of listener-supported internet radio stations. Many of them are low-lyrics or no-lyrics, and all are chill and contemplative in their different ways. Also no ads, just the occasional beg for donations.

In addition to the iTunes-compatible streams they also have apps for iOS and even Mac (I usually use the Mac one, though it’s got some bugs).

Some days I wonder why I don’t get anything done, other days I remember to turn on SomaFM. Here are my favorite stations (descriptions from the SomaFM site):

Drone Zone

Drone Zone: ambient commercial-free radio from SomaFM Served best chilled, safe with most medications. Atmospheric textures with minimal beats.

Digitalis

Digitalis: electronica/alternative commercial-free radio from SomaFM
Digitally affected analog rock to calm the agitated heart.

cliqhop idm

cliqhop idm: electronica commercial-free radio from SomaFM
Blips’n’beeps backed mostly w/beats. Intelligent Dance Music.

Beat Blender

Beat Blender: electronica commercial-free radio from SomaFM
A late night blend of deep-house and downtempo chill.

NetBeans Color Scheme: Solarized Dark with PHP Tweaks

Jump to download and installation instructions »

What is Solarized?

solarized logoSolarized is a programming color “palette” designed  by Ethan Schnoonover for use when writing syntax-highlited code. It’s based on color wheel and lightness relationships and it’s all sciencey and stuff, but the essence is that all the colors look good together and have good contrast, so you can use the different colors for different parts of your code (functions, variables, strings etc.) and no matter how you organize it the result should be easy on the eyes. It also has both a “dark” and “light” mode with different background/foreground colors, but most of the colors (red, green, magenta) work the same for both, which is cool.

Here’s a color reference I put together showing the various colors in Solarized Dark along with their RGB and hex codes. It was very useful to have around while working on the NetBeans theme (the Solarized site is strangely lacking a similar reference).

My Solarized Dark theme for NetBeans+PHP

As soon as I heard about Solarized I wanted to try it out with NetBeans, my IDE of choice for PHP/WordPress coding. I’ve spent many an hour tweaking my color schemes in NetBeans (and Smultron, my old text editor before that) and choosing the color relationships was always the hardest part, so having classy choices all laid out for me was very appealing.

The good news was that there is already a NetBeans port of the Solarized colors that worked as advertised. The problem was that IMHO it wasn’t particularly well executed. NetBeans has a lot of options in the color scheme settings, but they are also extremely confusing and often flat-out misleading, so I don’t blame the original author for not getting it perfect. He also may not have been looking at PHP code, in which case it makes sense that the PHP-specific color settings weren’t well organized. Lastly there’s a huge element of personal taste, even within the process of implementing a preset color theme like Solarized, so I recognize that the result is really just my personal opinion of what NetBeans+PHP+Solarized should look like.

All that said, here’s a screenshot of my NetBeans Solarized Dark theme:
Screenshot of my solarized dark theme for Netbeans

I like to think it balances the need to have different parts of the code be different colors and the limitations of doing so using the NetBeans color settings. It should work just as well with procedural and object-oriented code.

One feature I added that isn’t in the original Solarized for Netbeans colors is SVN support. I had to invent them, but my theme has appropriate red, green and blue background colors when viewing a SVN DIFF.

Installing my theme in your NetBeans

Since NetBeans has a configuration import/export system you can install these colors really easily.

  1. Download the .zip file linked below (don’t unzip it, NetBeans wants it as .zip).
  2. Open NetBeans and summon the Preferences window (Options on Windows).
  3. Go to the Fonts & Colors Preference tab.
  4. Click Import at the bottom of the window.
  5. Click Browse and find the .zip file, click OK.

Download netbeans-colors-solarized-dark-jer.zip »

Once you have the theme installed it should show up in the Fonts & Colors preferences as part of the Profile pulldown menu, where it’s identified as Netbeans_Solarized_Dark-jer.

Since I started using this I pretty much never feel the need to use a “light” theme so I haven’t tweaked the Solarized Light colors at all. Sorry if that’s what you would have preferred ;)

Anyway, hope some of you find this useful! I plan to someday get some of my changes added to the official GitHub repo, but wanted to get this out before my Code Faster and Smarter PHP with IDEs Like NetBeans talk tomorrow at WordCamp Montreal.

Video of my DRY CSS talk

It’s not exactly a thrill ride, coming in at 51 minutes, but here’s the full audio+slides video of my presentation about DRY CSS, my “simple yet powerful CSS architecture that avoids duplication and increases design consistency by grouping shared properties together rather than redefining them over and over”. Sorry there’s not footage of my pretty face, I recorded this using Screen Capture in QuickTime and Voice Memos on my iPhone (using the earbud mic).

For the impatient, you can also go through just the slides on slideshare.

DRY CSS – Slides from my ConFoo 2012 talk

Here’s the video with slides+audio of talk in case you prefer that. It’s 51min

This is an idea/talk that has literally been years in the making. Ever since I used this “DRY CSS” system for the Global Voices redesign I’ve been meaning to do the background research and lay it all out clearly like this. To me the core principle is so simple and standards-based that I have trouble believing it’s not already a thing, but I can’t find anyone else promoting it so here you go:

Embed should be above, here’s a direct link to the slideshare page: DRY CSS – A don’t-repeat-yourself methodology for creating efficient, unified and Scalable stylesheets »

Or if you prefer you can download the slides as a PDF »

Let me know what you think! Am I crazy? Why aren’t we already doing it this way?

A Love Poem in PHP

Wrote this a long time ago but never posted it. Stumbled onto it while cleaning up my email:

<?php
	$me = new Lover;

	$me->partner = $you;

	$me->feelings = array('adore','miss','want','love');

	foreach ($feelings as $feeling) {

		$me->express_feeling($feeling);

		if ($you->feeling_mutual($feeling))
			$me->epic_hugs($you);
	}
?>

Sure, it’s not the most expressive form of writing out there, but like with Haiku I think the limitation and challenge of putting poetry into code form can help push you to create something really fresh and strange without the baggage and cliché feel of regular poetry. I also just love naming variables and methods ;)

Either way, I think my poem is at least more uplifting than this other PHP love poem I found.

It was actually a follow-up to a shorter, twitter-length PHP love poem I wrote around the same time:

<?php
	$things_i_dont_miss_about_you = array();
?>

Submit your coded love poems in the comments, bonus points if it could at least theoretically execute in real life (assuming for example things like the existence of a “Lover” class with an express_feeling() method). If you’ve got the time write us an Epic PHP Poem, including all the needed class definitions :P

iOS apps worth considering

A friend emailed a few people to ask for recommendations of what to install on her new iDevice. My reply was detailed enough I thought you might be interested too. Seasoned iOS experts will yawn at the list because a lot of these are commonly accepted good choices, but if you don’t spend time each day on apps you’ll probably find something you didn’t know about below.

Note: I’m too lazy to find links for them all. Open up iTunes and search and you should be able to find them pretty fast.

Continue reading “iOS apps worth considering”