Skip to content

Instantly share code, notes, and snippets.

View kruchai's full-sized avatar
🇺🇦
Be brave like Ukraine

Oleg Kruchai kruchai

🇺🇦
Be brave like Ukraine
View GitHub Profile
@kruchai
kruchai / jsonPuller
Last active June 9, 2021 14:33 — forked from crstamps2/jsonPuller
A Google apps script to pull json from a spreadsheet.
function doGet(){
var ss = SpreadsheetApp.openById("//key ommitted");
return exportJSON(ss);
}
// Exports current sheet as JSON and displays in message box.
function exportJSON(ss) {
var sheet = ss.getSheetByName("sessions");
var rowsData = getRowsData(sheet);
var result = Utilities.jsonStringify(rowsData);
@kruchai
kruchai / composer.json
Created February 14, 2018 13:36 — forked from andyshinn/composer.json
Docker Compose PHP Composer Example
{
"require": {
"mfacenet/hello-world": "v1.*"
}
}
@kruchai
kruchai / router.html
Created February 6, 2018 13:06 — forked from joakimbeng/router.html
A really simple Javascript router
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Building a router</title>
<script>
// Put John's template engine code here...
(function () {
// A hash to store our routes:
@kruchai
kruchai / Singularitygs + Breakpoint + Compass with Gulp
Created January 26, 2018 13:30
Singularitygs + Breakpoint + Compass with Gulp
This is how I managed to set up Singularitygs + Breakpoint + Compass with Gulp (for Drupal theming).
Install gulp globally
"sudo npm install -g gulp"
Copy the following package.json to the root folder of your project.
{
"name": "your_project",
"version": "1.0.0",
@kruchai
kruchai / settings.local.php
Created January 11, 2017 15:00 — forked from isramv/settings.local.php
Example of D8 settings.local.php
<?php
/**
* @file
* Local development override configuration feature.
*
* To activate this feature, copy and rename it such that its path plus
* filename is 'sites/example.com/settings.local.php', where example.com
* is the name of your site. Then, go to the bottom of
* 'sites/example.com/settings.php' and uncomment the commented lines that
@kruchai
kruchai / .vimrc
Created November 11, 2016 14:21 — forked from kaido24/.vimrc
Vim config for Drupal project development
" Allow Vim-only settings even if they break vi keybindings.
set nocompatible
" Enable filetype detection.
filetype off
filetype plugin indent on
" Enable syntax highlighting
if &t_Co > 1
syntax enable
@kruchai
kruchai / bootstrap_theme_generate.sh
Created November 11, 2016 14:19 — forked from kaido24/bootstrap_theme_generate.sh
Generate Drupal 8 Bootstrap LESS prepared subtheme with grunt config.
#!/bin/bash -x
echo Are you at themes folder y/n?
read IS_THEME_FOLDER
if [ $IS_THEME_FOLDER != 'y' ];then
exit
fi
if ! [ -d bootstrap ];then
drush dl bootstrap
fi