Skip to content

Instantly share code, notes, and snippets.

View dimitri-koenig's full-sized avatar

Dimitri König dimitri-koenig

View GitHub Profile
@dimitri-koenig
dimitri-koenig / deploy.sh
Created June 14, 2018 09:17 — forked from BenSampo/deploy.sh
Laravel deploy script
# Change to the project directory
cd /home/forge/domain.com
# Turn on maintenance mode
php artisan down
# Pull the latest changes from the git repository
git pull origin master
# Install/update composer dependecies
@dimitri-koenig
dimitri-koenig / MyComponents.jsx
Created March 4, 2018 17:43 — forked from SachaG/MyComponents.jsx
Quick Apollo Mutations
// define component1, component2, etc. here
// will pass mutation as this.props.myMutation
export default withMutation({
name: 'myMutation',
args: {foo: 'String', bar: 'String'},
})(component1);
// will pass mutation as this.props.myOtherMutation
// this time, we don't have any arguments

Setup Work

  • Make a list of competitive/alternative services: See competitors.md file
  • Set up Google News alerts for "side project marketing" and "startup marketing".
  • Make list of blogs, subscribe to RSS feeds in Feedbin:
    • Startup marketing blogs
    • Side project blogs
    • Small business marketing blogs
    • Chicago small business/startup bloggers
  • Come up with a name and domain name
@dimitri-koenig
dimitri-koenig / ICS.php
Last active July 10, 2017 09:42 — forked from jakebellacera/ICS.php
A convenient script to generate iCalendar (.ics) files on the fly in PHP.
<?php
/**
* ICS.php
* =======
* Use this class to create an .ics file.
*
* Usage
* -----
* Basic usage - generate ics file contents (see below for available properties):
@dimitri-koenig
dimitri-koenig / gist:e21c9ca68f127554c2dc0e6a665c3a34
Created May 22, 2017 18:33 — forked from micronax/gist:6319186
Alle Shopware-Artikel aus der Datenbank entfernen + Media-DB für Artikel leeren. Achtung: Artikelbilder müssen noch manuell vom Server entfernt werden /media/img/
SET FOREIGN_KEY_CHECKS = 0;
TRUNCATE TABLE `s_articles`;
TRUNCATE TABLE `s_articles_attributes`;
TRUNCATE TABLE `s_articles_categories`;
TRUNCATE TABLE `s_articles_categories_ro`;
TRUNCATE TABLE `s_articles_details`;
TRUNCATE TABLE `s_articles_img`;
TRUNCATE TABLE `s_articles_prices`;
TRUNCATE TABLE s_article_configurator_sets;
TRUNCATE TABLE s_article_configurator_set_group_relations;
@dimitri-koenig
dimitri-koenig / flexform.xml
Created April 13, 2017 14:36 — forked from alrnz/flexform.xml
TypoLink in flexform for TYPO3 7.6
<settings.link>
<TCEforms>
<exclude>1</exclude>
<label>
Link to Page or a File or a Content-Element
</label>
<config>
<type>input</type>
<size>30</size>
<eval>trim</eval>
@dimitri-koenig
dimitri-koenig / gulpfile.js
Created February 17, 2017 17:14 — forked from bigsweater/gulpfile.js
Sage gulpfile with Browserify Hot Module Reloading, sourcemaps, and asset revisioning
/* eslint-disable */
// ## Globals
var argv = require('minimist')(process.argv.slice(2));
var autoprefixer = require('gulp-autoprefixer');
var browserSync = require('browser-sync').create();
var changed = require('gulp-changed');
var concat = require('gulp-concat');
var flatten = require('gulp-flatten');
var gulp = require('gulp');
var gulpif = require('gulp-if');
@dimitri-koenig
dimitri-koenig / mount.sh
Created January 26, 2017 14:09
Optimal sshfs mount params
#!/bin/bash
sudo sshfs -o volname=targetVolumeName,follow_symlinks,reconnect,auto_cache,noappledouble,negative_vncache,allow_other,defer_permissions,IdentityFile=/Users/me/.ssh/id_rsa user@server:/path/on/server /local/path/to/target/volume
SetEnvIfNoCase Request_URI "(specialRequest\/call|\.(jpg|jpeg|xml|png|gif|ico|js|css|swf|eot|ttf|woff|woff2))" DontLog
SetEnvIfNoCase User-Agent (crawler|bot|spider|yahoo|slurp|ltx71|statuscake) DontLog
SetEnvIf Request_URI "specialRequest\/call" specialRequestLog
SetEnvIfNoCase User-Agent (crawler|bot|spider|yahoo|slurp|ltx71|statuscake) bot
CustomLog /var/www/project/static/log/access.log combined Env=!DontLog
CustomLog /var/www/project/static/log/access-specialRequest.log combined Env=specialRequestLog
CustomLog /var/www/project/static/log/access-bot.log combined Env=bot
@dimitri-koenig
dimitri-koenig / login.php
Created September 18, 2016 15:11
Behat Laravel Login As
<?php
function iAmLoggedIn()
{
// Destroy the previous session
if (Session::isStarted())
{
Session::regenerate(true);
}
else