Symfony2 + Braincrafted/Bootstrap + BootSwatch(or any other scss/less theme)

I ran into an issue today where I needed to theme bootstrap. I also wanted to use all the the cool Symfony2 form features Braincrafted/Bootstrap gave me.

Braincrafted/Bootstrap is quite customizable but I went through a few trials to get it right so I figured I would share with the world.

This should work for any LESS based theme not just Bootstrap.

Adding New Theme

Create a new theme directory.

$ mkdir app/Resources/less/themes/[new_theme]

Copy all the required less files into the theme.

$ cp ~/Download/myTheme/*.less app/Resources/less/themes/[new_theme]

Create a LESS builder file in your theme diretory.


@import "variables.less";
@import "bootswatch.less";

Switching themes

Tell Assetic that you are going to use a custom less file.

                - %kernel.root_dir%/Resources/less/bootstrap.less
                - less
                - cssrewrite
            output: css/bootstrap.css

Point BrainCrafted/Bootstrap at the builder file:


        variables_file: %kernel.root_dir%/Resources/less/themes/[new_theme]/bootstrap.less

Generate a new master bootstrap file:

$ php app/console braincrafted:bootstrap:generate

Then install the assets:

$ php app/console assetic:dump

Clear the cache:

$ php app/console cache:clear

Amazon Fire Stick/Fire TV + PS4 DualShock controller (working… sorta)

See Update at bottom for Fire TV tests!

I am going to lay everything out upfront. With my Amazon Fire Game Controller not arriving for 2-4 months, the Nyko (PlayPad Pro and PlayPad”Android”) not available and my brand new Amazon Fire Stick in hand I wanted to play Terarria. Doh, who doesn’t? So, I sat down to hook up a PS4 DualShock controller.

The end result was a working but a slow and almost unresponsive controller. I suspect that the large amount of data the controller is trying to push with all of its cool gismos is just to much for the little stick.

So, lets get to the rig, for science or whatever.

Continue reading


Getting started with CLI Android development [android part 1]

It’s time to do some Android App development and Eclipse drives me up the wall. So I am going to document how to do this my way. The CLI way. I plan on using Lollipop, so SDK API 21 will be our target build and our IDE, vim. That’s my go to bad-boy editor. When we are done we should be about to build a default android app, on a remote POSIX server, like any real BOSS. Continue reading