Skip to content

Instantly share code, notes, and snippets.

View rtablada's full-sized avatar

Ryan Tablada rtablada

View GitHub Profile
./configure \
--prefix=/usr \
--mandir=/usr/share/man \
--infodir=/usr/share/info \
--sysconfdir=/private/etc \
--with-apxs2=/usr/sbin/apxs \
--enable-cli \
--with-config-file-path=/etc \
--with-libxml-dir=/usr \
--with-openssl=/usr \
@rtablada
rtablada / File Tree
Last active December 18, 2015 03:18
This is an idea for a Guard based Asset Pipeline for Laravel 4
app/
|-assets/
| |-coffee/
| | |-main.coffe
| |-less/
| | |-main.less
public/
|-assets
| |-css
@rtablada
rtablada / Guardfile
Created June 6, 2013 16:09
When I save a file, the less is properly compiled, but the css is not concatenated.
guard :coffeescript, :input => "app/assets/coffee", :output => "public/src/js"
guard :less, :all_on_start => true, :all_on_start => false, :output => 'public/src/css' do
watch(%r[^app/assets/less/(.+\.less)$])
end
guard :concat, :type => "css", :files => %w[], :input_dir => "public/src/css", :output => "public/assets/css/hello"
guard :concat, :type => "js", :files => %w[], :input_dir => "public/src/js", :output => "public/src/js/hello"
# Refresh the browser on save
guard 'livereload' do
watch(%r{.+(?<!\.min)\.(css|html|js|blade\.php)$})
@rtablada
rtablada / provides.json
Last active December 18, 2015 05:19
Proposal for laravel specific package helpers
{
"serviceProviders": [
"Vendor\Namespace\ServiceProvider"
],
"facades": [
{
"alias": "Alias",
"facade": "Path\To\Facade"
}
]
@rtablada
rtablada / provides.json
Last active December 18, 2015 05:59
This is an example provides.json for Laravel Packages as proposed in this [proposal](https://github.com/laravel/framework/issues/1578). This works with the [package installer](https://github.com/rtablada/package-installer) package.
{
"providers": [
"Illuminate\Html\HtmlServiceProvider"
],
"aliases": [
{
"alias": "HTML",
"facade": "Illuminate\Support\Facades\HTML"
}
]
@rtablada
rtablada / gist:5736789
Last active December 18, 2015 05:59
This is how to install an updated version of Guard Less to work with Bootstrap.

Move to a temporary or downloads folder then run

  • git clone https://github.com/dwt/guard-less.git
  • cd guard-less
  • gem build guard-less.gemspec
  • gem install ./guard-less-0.1.3.gem

You may need to run some of these as su

<?php
return array(
/*
|--------------------------------------------------------------------------
| Application Debug Mode
|--------------------------------------------------------------------------
|
| When your application is in debug mode, detailed error messages with
@rtablada
rtablada / Topics.md
Last active December 19, 2015 09:59
Possible topics for a book on advanced PHP application deployment
  • Linux Basics
  • VPS Basics
  • Intro to git
  • Git Feature Strategies
  • Capistrano, Chef, or, Puppet
  • Private VCS Repositories
  • Composer
  • Private Composer Packages
  • Nginx Setup
  • SSH key setup
<?php namespace Gateways;
use Illuminate\Support\ServiceProvider;
class GatewaysServiceProvider extends ServiceProvider {
/**
* Indicates if loading of the provider is deferred.
<snippet>
<content><![CDATA[
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>${1:title}</title>
</head>