Skip to content

Instantly share code, notes, and snippets.


Paul Samsotha psamsotha

View GitHub Profile
davejamesmiller /
Last active Oct 28, 2020
Laravel's Dependency Injection Container in Depth

Laravel's Dependency Injection Container in Depth

Translations: Korean (by Yongwoo Lee)

Laravel has a powerful Inversion of Control (IoC) / Dependency Injection (DI) Container. Unfortunately the official documentation doesn't cover all of the available functionality, so I decided to experiment with it and document it for myself. The following is based on Laravel 5.4.26 - other versions may vary.

Introduction to Dependency Injection

I won't attempt to explain the principles behind DI / IoC here - if you're not familiar with them you might want to read What is Dependency Injection? by Fabien Potencier (creator of the Symfony framework).


Basic Syntax

$ scp source_file_path destination_file_path


Single file

fikovnik / build.gradle
Created May 8, 2016
Building maven plugins by gradle
View build.gradle
configurations {
dependencies {
compile "org.apache.maven:maven-core:$mavenVersion"
compile "org.apache.maven:maven-plugin-api:$mavenVersion"
compile 'org.apache.maven.plugin-tools:maven-plugin-annotations:3.4'
mavenEmbedder "org.apache.maven:maven-embedder:$mavenVersion"
btroncone /
Last active Oct 27, 2020
A Comprehensive Introduction to @ngrx/store - Companion to Series

Comprehensive Introduction to @ngrx/store

By: @BTroncone

Also check out my lesson @ngrx/store in 10 minutes on!

Update: Non-middleware examples have been updated to ngrx/store v2. More coming soon!

Table of Contents

tveimo / uploadtest.jsp
Last active Nov 29, 2017
single submit file upload example with the jquery file upload plugin:
View uploadtest.jsp
<%@ page language="java" pageEncoding="UTF-8" contentType="text/html;charset=UTF-8" %>
<!DOCTYPE html>
<script src="//"></script>
<script src="//"></script>
<script src="//"></script>
<script src="//"></script>
<script src="//"></script>
<script src="//"></script>
View sed cheatsheet
# double space a file
sed G
# double space a file which already has blank lines in it. Output file
# should contain no more than one blank line between lines of text.
sed '/^$/d;G'
postmodern / Makefile
Last active Sep 28, 2020
A generic Makefile for building/signing/install bash scripts
View Makefile
DIRS=etc lib bin sbin share
INSTALL_DIRS=`find $(DIRS) -type d 2>/dev/null`
INSTALL_FILES=`find $(DIRS) -type f 2>/dev/null`
DOC_FILES=*.md *.txt
You can’t perform that action at this time.