Skip to content

Instantly share code, notes, and snippets.

Avatar
👨‍🚀
coding something...

Ashley Clarke clarkeash

👨‍🚀
coding something...
View GitHub Profile
@clarkeash
clarkeash / nodemon.json
Created Mar 11, 2020
Nodemon config for Laravel
View nodemon.json
{
"events": {
"start": "clear",
"restart": "clear"
},
"exec": "php artisan test",
"ext": "*",
"ignore": [
"vendor/"
]
@clarkeash
clarkeash / TestCase.php
Last active Feb 9, 2016
Laravel TestCase Improved
View TestCase.php
<?php
class TestCase extends Illuminate\Foundation\Testing\TestCase
{
/**
* The base URL to use while testing the application.
*
* @var string
*/
protected $baseUrl = 'http://localhost';
@clarkeash
clarkeash / phpunit.xml
Last active Jan 27, 2016
Standard phpunit configuration. (adapted from Laravel)
View phpunit.xml
<?xml version="1.0" encoding="UTF-8"?>
<phpunit backupGlobals="false"
backupStaticAttributes="false"
bootstrap="vendor/autoload.php"
colors="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false">
@clarkeash
clarkeash / example.php
Last active Aug 29, 2015
16-October-sample-post
View example.php
<?php
echo "hey, there!";
?>
View keybase.md

Keybase proof

I hereby claim:

  • I am clarkeash on github.
  • I am clarkeash (https://keybase.io/clarkeash) on keybase.
  • I have a public key whose fingerprint is 27AC 45CC 3588 C999 69F3 A3A8 5727 16D2 B57C C18F

To claim this, I am signing this object:

View this.php
<?php
class This {
protected $this;
public function __construct ()
{
$this->this = $this;
}
View Envoy.blade.php
/*
|--------------------------------------------------------------------------
| Basic Setup/Config
|--------------------------------------------------------------------------
*/
@setup
$directory = '/home/vagrant/laravel-apps/stubb-project';
@endsetup
/*
View gist:e0a67e738559a98e64ac
Config:
- Change scrolling direction
- Hide dock
- Create SSH key
- Pull in bash profile from github
Apps:
- Chrome
- Dropbox
- Alfred App
@clarkeash
clarkeash / object_one.js
Created Dec 5, 2013
New to objects in JS, no idea of the differences here: (why would you use one over the other)
View object_one.js
function Object(){
}
Object.prototype.func = function(){
//code
};
View StringToArrayWithMultipleSplitsThingy.php
<?php
function splitAndStrip($str, $del = ',')
{
$str = explode($del, $str);
for ($i=0; $i < count($str); $i++)
{
$str[$i] = trim($str[$i]);
}
return $str;
}