Skip to content

Instantly share code, notes, and snippets.

View gist:5b81d62ae49415df4e9c3cc657964118
/* Plugin Name: My Plugin */
include( dirname( __FILE__ ) . '/library/admin-page-framework.php' );
if ( ! class_exists( 'MyPluginName_AdminPageFramework' ) ) {
class MyPluginName extends MyPluginName_AdminPageFramework {
//... Start code here ...
bugsysop /
Created Dec 18, 2020 — forked from brunoamaral/
This script takes a folder with image files and converts them to page bundles to be used with
for file in *
date=`cut -d' ' -f 1 <<< "$file"`
mkdir "$dir"
mv "$file" "$dir"
time=`cut -d' ' -f 2 <<< "$file" | sed -e 's/\./\:/g'`
printf '%s\n' '---' 'categories: ["instagram"]' "date: $datetime" 'description: ""' 'draft: false' 'resources:' " - src: '$file'" ' name: "header"' 'layout: instagram' 'slug:' 'stories:' 'subtitle:' 'title: Untitled' 'options:' ' unlisted: false' ' showHeader: true' '---' '' "<img src=\"$file\" />" | tee $dir/ $dir/
bugsysop /
Created Dec 18, 2020 — forked from brunoamaral/
a simple script to password protect a directory on nginx
read -p "Website nginx directory without trailling slash [/var/web/]:" publicDir
read -p "Which directory should we protect? (no trailling slash)" relUrl
htpasswd -c "$publicDir$relUrl/.htpasswd" nginx;
cp "$publicDir$relUrl/.htpasswd" "$SOURCEDIR$relUrl"
bugsysop /
Created Mar 1, 2020 — forked from arthurattwell/
Split a markdown file into separate files on YAML frontmatter
# That tells Linux to use a Bourne shell interpreter.
# Run this script from the current directory. (Required on OSX.)
cd -- "$(dirname "$0")"
# Don't echo these commands.
set +v
# Get the filename from the user.
bugsysop / getLastRSSFeed.html
Created Nov 11, 2019 — forked from juanbrujo/getLastRSSFeed.html
Get and display last feed from RSS using JavaScript (jQuery)
View getLastRSSFeed.html
<div class="noticia">CARGANDO</div>
<script src=""></script>
var url = '';
var news = $('.noticia');
View How to change Pantheon Terminal's color

How to change Pantheon Terminal's color scheme

Many of us spend many hours of our days using their terminal. Plus, we all have different tastes when it comes to color schemes. That's why the ability to change the color scheme of a terminal is one of its more important featuresl. Throughout this tutorial, I'll teach you how you can change the looks of your terminal, step by step.

This tutorial is aimed at elementary OS users, but it also works for any Ubuntu user. Start by installing dconf-tools:

sudo apt-get install dconf-tools

Secondly, you need to decide which theme you're going to apply. You can find dozens of terminal color schemes online, you can even design your own using this web application. Design the color scheme, hit "Get Scheme" and choose "Terminator". You'll get a raw text file with a background color, a foreground color and a palette. Those strings define your color scheme. In this tutorial, I'll post an

bugsysop /
Created Jun 30, 2019 — forked from trongthanh/
Apply custom color theme for Pantheon Terminal ver 5.3+
# Apply custom color theme for Pantheon Terminal ver 5.3+
# 1) preview and choose a color theme from
# 2) open the equivalent bash file containing the color values at
# 3) concatenate all 16 colors at the top with colon ":", then replace it at the palette variable below
# 4) replace color for foreground, background, and cursor; choose whether your theme is light or dark
# 5) sudo apt-get install dconf-tools
# 6) execute this script
View wf-logo-1.css
#blog-title a {
background: transparent url('') no-repeat bottom left;
padding-left: 42px;
View .htaccess
# Add correct content-type for fonts
AddType application/ .eot
AddType font/ttf .ttf
AddType font/otf .otf
AddType font/x-woff .woff
AddType image/svg+xml .svg
# Compress compressible fonts
AddOutputFilterByType DEFLATE font/ttf font/otf image/svg+xml