Skip to content

Instantly share code, notes, and snippets.

View sean-e-dietrich's full-sized avatar

Sean Dietrich sean-e-dietrich

View GitHub Profile
@matthewpalmer
matthewpalmer / pod.yaml
Created July 21, 2018 04:13
kubernetes nginx php-fpm pod
# Create a pod containing the PHP-FPM application (my-php-app)
# and nginx, each mounting the `shared-files` volume to their
# respective /var/www/html directories.
kind: Pod
apiVersion: v1
metadata:
name: phpfpm-nginx-example
spec:
volumes:
@crittermike
crittermike / import.php
Last active August 28, 2024 06:43
Importing Drupal 8 config programmatically
<?php
// Import arbitrary config from a variable.
// Assumes $data has the data you want to import for this config.
$config = \Drupal::service('config.factory')->getEditable('filter.format.basic_html');
$config->setData($data)->save();
// Or, re-import the default config for a module or profile, etc.
\Drupal::service('config.installer')->installDefaultConfig('module', 'my_custom_module');
@a-r-m-i-n
a-r-m-i-n / bash.sh
Created May 13, 2017 16:50
How to install TYPO3 from commandline
cd /var/www/html
rm -Rf *
composer require typo3/cms:"^7.6" helhum/typo3-console:"^4.5" gridelementsteam/gridelements:"^7.1"
vendor/bin/typo3cms install:setup --force --database-user-name "root" --database-user-password "" --database-host-name "localhost" --database-name "typo3_76" --database-port "3306" --database-socket "" --admin-user-name "admin" --admin-password "password" --site-name "TYPO3 Project" --site-setup-type "site" --use-existing-database 0
vendor/bin/typo3cms cache:flush
php typo3/cli_dispatch.phpsh extbase extension:install gridelements
@arkadiusjonczek
arkadiusjonczek / gist:8836e724a53ddd55362644745cf8ca4c
Created December 31, 2016 01:30
Start Chrome in App Mode on Mac OS X
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --app="http://www.google.de"
@vital101
vital101 / nodegit.js
Created September 26, 2016 10:36
NodeGit Clone Private with Token
const repo = 'vital101/kernl-example-plugin-gitub';
const token = 'my-token-from-oauth';
const cloneURL = `https://${token}:[email protected]/${repository}`;
const cloneOptions = {
fetchOpts: {
callbacks: {
certificateCheck: () => { return 1; },
credentials: () => {
return NodeGit.Cred.userpassPlaintextNew(token, 'x-oauth-basic');
}
@ECHO OFF
REM -- Automates cygwin installation
SETLOCAL
REM -- Change to the directory of the executing batch file
CD %~dp0
REM -- Configure our paths
SET SITE=http://mirrors.kernel.org/sourceware/cygwin/