Skip to content

Instantly share code, notes, and snippets.

@hamzamu
hamzamu / project-create.sh
Created May 5, 2019 16:49 — forked from francoisromain/project-create.sh
A bash script to create a Git post-receive hook to deploy after a Git push
#!/bin/bash
# Call this file with `bash ./project-create.sh project-name [service-name]`
# - project-name is mandatory
# - service-name is optional
# This will creates 4 directories and a git `post-receive` hook.
# The 4 directories are:
# - $GIT: a git repo
# - $TMP: a temporary directory for deployment
@hamzamu
hamzamu / README.md
Created March 6, 2019 12:03 — forked from rayfranco/README.md
Inline SVG with Nuxt

Inline SVG with Nuxt

I was looking for a SSR and scoped styles ready solution to implement inline SVG with Nuxt

You need svg-inline-loader and xmldom to be installed.

@hamzamu
hamzamu / git-deployment.md
Created February 15, 2019 10:13 — forked from noelboss/git-deployment.md
Simple automated GIT Deployment using Hooks

Simple automated GIT Deployment using GIT Hooks

Here are the simple steps needed to create a deployment from your lokal GIT repository to a server based on this in-depth tutorial.

How it works

You are developing in a working-copy on your local machine, lets say on the master branch. Most of the time, people would push code to a remote server like github.com or gitlab.com and pull or export it to a production server. Or you use a service like my Deepl.io to act upon a Web-Hook that's triggered that service.

System process daemons that are system-wide provided by mac os x are described by launchd preference files that can be showed with the command:
$ sudo ls -all /System/Library/LaunchDaemons/
Third party process daemons that are system-wide provided by the administrator are described by preference files that can be showed with the command:
$ sudo ls -all /Library/LaunchDaemons/
Launch Agents that are per-user provided by mac os x usually loaded when the user logs in. Those provided by the system can be found with:
$ sudo ls -all /System/Library/LaunchAgents/
Launch Agents that are per-user provided by the administrator and usually loaded when the user logs in. Those provided by the system can be found with:
!! TODO tasks
<$list filter="[!has[draft.of]tag[task]!tag[done]sort[created]]">
<$checkbox tag="done"> <$link to={{!!title}}><$view field="title"/></$link></$checkbox>
</$list>
!! Completed tasks
@hamzamu
hamzamu / Love2D_KeyTest.lua
Created June 6, 2018 09:27 — forked from biomood/Love2D_KeyTest.lua
Love2D code for seeing what key/joystick button is pressed
game = {}
game.button= ""
game.key = ""
function love.load()
success = love.graphics.setMode(320, 240, false, 0)
end
function love.update(dt)
end
@hamzamu
hamzamu / OOP_inheritance.html
Created June 25, 2017 11:01 — forked from Philipp-M/OOP_inheritance.html
OOP Inheritance in Vue.js
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>vue inheritance</title>
</head>
<body>
<my-student></my-student>
<my-student first-name="Franz" last-name="Meier" :student-id="54321"></my-student>
<my-professor first-name="Jared" last-name="Josey"></my-professor>
@hamzamu
hamzamu / meteor-ddp.md
Created January 30, 2017 06:41
MeteorJS DDP Protocol Docs

DDP Specification

DDP is a protocol between a client and a server that supports two operations:

  • Remote procedure calls by the client to the server.
  • The client subscribing to a set of documents, and the server keeping the client informed about the contents of those documents as they change over time.

This document specifies the version "pre1" of DDP. It's a rough description of

<html>
<head>
<title>API Example</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<script src="http://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<script type="text/javascript">
var accessToken = "<your agent's client access token>";
var baseUrl = "https://api.api.ai/v1/";
@hamzamu
hamzamu / smoke.lua
Created December 5, 2016 06:22
First attempt at a smoke particle effect in love2d.
function love.load()
particles = {}
particles.clock = 0
particles.acceleration = {x = love.math.random(-50, 50), y = love.math.random(-50, 50)}
end
function love.update(dt)
local remove = {}
for i, particle in ipairs(particles) do