Skip to content

Instantly share code, notes, and snippets.

View b4oshany's full-sized avatar

Oshane Bailey b4oshany

View GitHub Profile
@b4oshany
b4oshany / instalGuillotinal.sh
Created October 19, 2017 13:54
Install script for Guillotina
#!/bin/bash
# Adding postgres and python 3 to our package sources
sudo su -c "echo \"deb http://apt.postgresql.org/pub/repos/apt/ trusty-pgdg main 9.6\" > /etc/apt/sources.list.d/postgresql.list"
wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
sudo add-apt-repository ppa:jonathonf/python-3.6 -y
sudo apt-get update -y
# Install python 3.6 dependencies
@b4oshany
b4oshany / base.cfg
Last active January 31, 2018 10:14
Plone versions.cfg from Docker
######################################################
# Base Configuration; this provides sane defaults
# for commonly used parts.
# ---------------------------------------------------
#
# Buildout instructions in this file are
# usually only changed by experienced developers.
#
# Beyond here there be dragons!
@b4oshany
b4oshany / install-node-bower.sh
Last active May 1, 2018 12:35
Install node js, npm and bower on Ubuntu
#!/bin/bash
sudo apt-get update
if [ -z $(which node) ]; then
# curl -sL https://deb.nodesource.com/setup | bash -
sudo apt-get install -y nodejs
fi
if [ -z $(which npm) ]; then
@b4oshany
b4oshany / accordion.css
Created May 21, 2018 06:05
Accordion static files
/** Accordion styles **/
.accordions {
background: white;
padding: 16px 8px;
}
.accordion {
background-color: white;
color: #444;
cursor: pointer;
@b4oshany
b4oshany / mosaic-bootstrap-rules.xml
Created September 4, 2018 20:53
Diazo recipe make the Plone Mosaic editor compatible with Bootstrap CSS grid.
<?xml version="1.0" encoding="UTF-8"?>
<rules
xmlns="http://namespaces.plone.org/diazo"
xmlns:css="http://namespaces.plone.org/diazo/css"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="2.0"
xmlns:xi="http://www.w3.org/2001/XInclude">
<!-- Transform Mosaic Grid to Bootstrap Grid -->
<rules css:content="body.mosaic-grid.template-layout">
<replace css:content=".mosaic-grid-row">
@b4oshany
b4oshany / plone.nginx.conf
Created September 9, 2018 18:05
Plone nginx.conf
upstream plone {
server 127.0.0.1:12030;
server 127.0.0.1:12031;
}
server {
server_name <<<Site>>>;
access_log /var/log/nginx/<<<Site>>>.access.log;
error_log /var/log/nginx/<<<Site>>>.error.log;
set $vh_protocol "https";
@b4oshany
b4oshany / installchrome.sh
Last active September 20, 2018 16:30
Robot Framework for Kotti
#!/bin/bash
BASE=$PWD
# from https://chromium.woolyss.com/
# and https://gist.github.com/addyosmani/5336747
# and https://chromium.googlesource.com/chromium/src/+/lkgr/headless/README.md
sudo apt-get update
sudo apt-get install -y libappindicator1 fonts-liberation
cd dumps
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo apt-get -y install dbus-x11 xfonts-base xfonts-100dpi xfonts-75dpi xfonts-cyrillic xfonts-scalable
@b4oshany
b4oshany / tinymce.keywords.robot
Created September 20, 2018 17:31
Robot Framework Keywords for TinyMCE
*** Settings ***
Documentation A resource file with reusable keywords and variables.
...
... The system specific keywords created here form our own
... domain specific language. They utilize keywords provided
... by the imported Selenium2Library.
Library Selenium2Library
*** Variables ***
${BROWSER} phantomjs
@b4oshany
b4oshany / upgrade-to-php7.sh
Last active November 18, 2018 01:52
Upgrade to PHP7
sudo add-apt-repository ppa:ondrej/php -y
sudo apt-get update -y
sudo apt-get install php7.0 -y
sudo apt-get install php7.0-mysql -y
sudo apt-get install php7.0-curl -y
sudo apt-get install php7.0-mbstring -y
sudo apt-get install php7.0-dom -y
@b4oshany
b4oshany / occupations.json
Created January 8, 2019 20:34
List of occupations
['Professor', 'Teacher', 'Actor', 'Clergy', 'Musician', 'Philosopher', 'Visual Artist', 'Writer', 'Audiologist', 'Chiropractor', 'Dentist', 'Dietitian', 'Doctor', 'Medical Laboratory Scientist', 'Midwive', 'Nurse', 'Occupational therapist', 'Optometrist', 'Pathologist', 'Pharmacist', 'Physical therapist', 'Physician', 'Psychologist', 'Speech-language pathologist', 'Accountant', 'Actuarie', 'Agriculturist', 'Architect', 'Economist', 'Engineer', 'Interpreter', 'Attorney at law', 'Advocate', 'Solicitor', 'Librarian', 'Statistician', 'Surveyor', 'Urban planner', 'Human resource', 'Firefighter', 'Judge', 'Military officer', 'Police officer', 'Air traffic controller', 'Aircraft pilot', 'Sea captain', 'Scientist', 'Astronomer', 'Biologist', 'Botanist', 'Ecologist', 'Geneticist', 'Immunologist', 'Pharmacologist', 'Virologist', 'Zoologist', 'Chemist', 'Geologist', 'Meteorologist', 'Oceanographer', 'Physicist', 'Programmer', 'Web developer', 'Designer', 'Graphic designer', 'Web designer', 'Software Developer', 'Entrepr