Skip to content

Instantly share code, notes, and snippets.

View lindstrm's full-sized avatar
🙃

Joachim Lindström lindstrm

🙃
View GitHub Profile
@gokulkrishh
gokulkrishh / media-query.css
Last active September 20, 2024 07:20
CSS Media Queries for Desktop, Tablet, Mobile.
/*
##Device = Desktops
##Screen = 1281px to higher resolution desktops
*/
@media (min-width: 1281px) {
/* CSS */
@jdforsythe
jdforsythe / connect.ps1
Last active August 23, 2024 12:09
Remote Desktop Auto Login Powershell Script
cmdkey /list | ForEach-Object{if($_ -like "*target=TERMSRV/*"){cmdkey /del:($_ -replace " ","" -replace "Target:","")}}
echo "Connecting to 192.168.1.100"
$Server="192.168.1.100"
$User="Administrator"
$Password="AdminPassword"
cmdkey /generic:TERMSRV/$Server /user:$User /pass:$Password
mstsc /v:$Server
@JeffreyWay
JeffreyWay / .bash_profile
Created July 31, 2015 19:20
Prettier git logs
alias gl="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit"
@AlcaDesign
AlcaDesign / index.html
Last active March 20, 2023 10:01
tmi.js with BTTV emotes
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>BTTV Emotes Gist</title>
<script src="https://code.jquery.com/jquery-2.1.4.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/underscore.js/1.8.3/underscore-min.js"></script>
<script src="https://d2g2wobxbkulb1.cloudfront.net/0.0.18/tmi.min.js"></script>
<script src="js/main.js"></script>
</head>
var base_path = __dirname.replace('resources/node', '');
require('dotenv').config({
path: base_path + '.env'
});
var env = process.env;
/* Illuminate\Auth\SessionGuard@getName */
var loginSHA1 = 'login_web_59ba36addc2b2f9401580f014c7f58ea4e30989d';
@mottihoresh
mottihoresh / PusherWrapper.php
Last active November 17, 2019 20:09
Basic Pusher Integration with Laravel 5
<?php
/**
* Created by PhpStorm.
* User: mhoresh
* Date: 3/7/15
* Time: 4:15 PM
*/
namespace App\Services;
@cyriac
cyriac / gitlab-omnibus-backup.sh
Created August 22, 2014 13:28
Gitlab Omnibus backup to Amazon S3
gitlab-rake gitlab:backup:create
find /var/opt/gitlab/backups -mtime +7 -exec rm {} \;
s3cmd sync --skip-existing --delete-removed /var/opt/gitlab/backups/ s3://<s3-bucket-name>/gitlab/backups/
@laracasts
laracasts / gulpfile.js
Last active February 10, 2024 10:57
Example Laravel-specific Gulpfile from Laracasts.com
var gulp = require('gulp');
var gutil = require('gulp-util');
var notify = require('gulp-notify');
var sass = require('gulp-ruby-sass');
var autoprefix = require('gulp-autoprefixer');
var minifyCSS = require('gulp-minify-css')
var coffee = require('gulp-coffee');
var exec = require('child_process').exec;
var sys = require('sys');
@JeffreyWay
JeffreyWay / .bash_profile
Created May 8, 2013 18:02
Laravel aliases
# laravel new-app
alias laravel="git clone -o laravel -b develop https://github.com/laravel/laravel.git"
alias artisan="php artisan"
alias migrate="php artisan migrate"
alias serve="php artisan serve"
alias dump="php artisan dump"
alias t="phpunit"
# Generators Package
@JeffreyWay
JeffreyWay / challenge.md
Last active February 25, 2019 01:36
Laravel challenge / poll for book.

Challenge: you need a flexible (swap in other repository implementations) way to display some kind of resource. Let's say, Posts. What does your folder structure look like?

Requirements:

  • Repository implements an interface
  • Must show at least one implementation of the interface (Eloquent version is fine)
  • The interface is injected into your PostsController.
  • Show where you register your IoC bindings
  • Show folder structure. Where are interfaces/repositories stored?