Skip to content

Instantly share code, notes, and snippets.

'use strict'
const gulp = require('gulp')
const babel = require('gulp-babel')
const sass = require('gulp-sass')
const uglifyCss = require('gulp-uglifycss')
const uglifyJs = require('gulp-uglify')
const concat = require('gulp-concat')
const ts = require('gulp-typescript')
const del = require('del')
#!/usr/bin/env php
<?php
declare(strict_types=1);
declare(ticks=1);
use Common\Helper\Logger;
if (PHP_SAPI !== 'cli') {
exit();
#!/usr/bin/env php
<?php
declare(strict_types=1);
use Amp\Loop;
use Cli\Sources\SourceFactory;
use Cli\Sources\SourceInterface;
use Common\Console\Application;
use Common\Helper\Logger;
FROM node:12.11.1-alpine
ENV ENVIRONMENT="production" \
DOCROOT="/var/www/html"
LABEL maintainer="[email protected]" \
product="app.node"
RUN apk add --no-cache --virtual .deps g++ gcc libgcc libstdc++ linux-headers make python &&\
npm install -g node-gyp less sass &&\
@yaredc
yaredc / run.sh
Last active October 14, 2019 19:28
#!/bin/sh
set -e
###########################################################
#DEFINE ALL GLOBAL INDEPENDENT HELPER FUNCTIONS
###########################################################
l() {
LEVEL="INFO"
FROM php:7.3-fpm-alpine
#PROD
ENV ENVIRONMENT="production" \
DOCROOT="/var/www/html"
RUN apk add --no-cache --virtual .deps autoconf tzdata build-base libzip-dev postgresql-dev \
libxml2-dev libxslt-dev libpng-dev zlib-dev freetype-dev jpeg-dev icu-dev &&\
docker-php-ext-install zip xml xsl pgsql mbstring json intl gd pdo pdo_pgsql iconv &&\
echo 'date.timezone="Europe/Berlin"' >> "${PHP_INI_DIR}"/php.ini &&\
.PHONY:up down build install uninstall clean dist
SHELL:=/bin/sh
ENV?=dev
TIMESTAMP:=$(shell date +"%Y.%m.%d.%H.%M.%S")
DIR_DIST:=$(shell pwd)/dist
TAR_DIST:=$(shell pwd)/dist.$(ENV).$(shell date +%s).tar.gz
DIR_ROOT:=$(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
DIR_MAKE:=$(shell mkdir -p $(shell pwd)/.make)
RUNNING_CONTAINERS_IDS:=$(shell docker-compose ps -q)
BUILD_PRE:=docker-compose.yaml $(shell ls -d .docker/dev/*)
@yaredc
yaredc / delete-git-history.md
Created September 8, 2019 11:51
Delete/reset history in GIT repository.

RESET (EFFECTIVELY DELETE) TARGETED BRANCH HISTORY

  1. Checkout tmp branch without history, from whatever targeted commit or branch you want
  2. Delete targeted branch
  3. Rename tmp branch to targeted branch
  4. Force push to repo

IN CASE OF master BRANCH

@yaredc
yaredc / provision-debian-10-01.sh
Last active September 9, 2019 21:19
Provisioning shell script for Debian 10.1
#!/bin/sh
sudo apt install -y tmux screen git mc vim docker docker-compose keepassx yubikey-manager \
htop vlc nvidia-detect chromium chromium-l10n gimp inkscape audacity &&
sudo apt update -y &&
sudo apt upgrade -y &&
sudo apt autoremove -y &&
sudo usermod -a -G docker $(whoami)
#CHECK WHICH DRIVERS ARE RECOMMENDED
@yaredc
yaredc / provision-ubuntu-19-04.sh
Last active September 9, 2019 21:19
Provisioning shell script for Ubuntu 19.04
#!/bin/sh
sudo apt install -y tmux screen git mc vim docker docker-compose keepassx yubikey-manager \
htop vlc nvidia-settings chromium-browser firefox gimp inkscape audacity unity-tweak-tool \
unity-control-center ubuntu-drivers-common &&\
sudo apt update -y &&
sudo apt upgrade -y &&
sudo apt autoremove -y &&
sudo usermod -a -G docker $(whoami)