Skip to content

Instantly share code, notes, and snippets.

# By default the behavior is:
# Primary monitor work as always and second monitor only have one and fixed workspace
# I.e. you change to next workspace, primary monitor change to this workspace and second monitor remain as is.
# The desired behaviour is:
# Primary monitor and secondary monitor are linked workspace.
# I.e. you change to next workspace, primary monitor change to this workspace and second monitor too.
$ gconf-editor
# Look for /desktop/gnome/shell/windows/workspaces_only_on_primary and set to false
@Frozenfire92
Frozenfire92 / inject.js
Last active August 29, 2015 14:23
Inject a library from a cdn in any website through the console
var s = document.createElement('script');
s.type = "text/javascript";
s.src = "https://code.jquery.com/jquery-2.1.4.min.js";
document.head.appendChild(s);
@Frozenfire92
Frozenfire92 / flux.sh
Last active August 29, 2015 14:24 — forked from robertmarsal/gist:9feaa9150926efa4175a
flux ubuntu 15.04
sudo apt-get install python-gconf python-glade2 python-appindicator
git clone https://github.com/Kilian/f.lux-indicator-applet.git
cd f.lux-indicator-applet
chmod +x setup.py
sudo ./setup.py install
fluxgui
@Frozenfire92
Frozenfire92 / D.cs
Last active August 29, 2015 14:26 — forked from onevcat/D.cs
Unity Better Debug script
#define DEBUG_LEVEL_LOG
#define DEBUG_LEVEL_WARN
#define DEBUG_LEVEL_ERROR
using UnityEngine;
using System.Collections;
// setting the conditional to the platform of choice will only compile the method for that platform
@Frozenfire92
Frozenfire92 / MoveComponentContext.cs
Last active August 29, 2015 14:26 — forked from AngryAnt/MoveComponentContext.cs
Adds "Move to Top" and "Move to Bottom" items to the inspector context menu of components.
using UnityEngine;
using UnityEditor;
public class MoveComponentContext
{
enum Destination
{
Top,
Bottom
@Frozenfire92
Frozenfire92 / gource.sh
Last active December 8, 2015 03:56 — forked from XueshiQiao/gource.sh
Generate a MP4 Video for your Git project commits using Gource!
gource \
-1920x1080 \
--seconds-per-day 2 \
--camera-mode overview \
--auto-skip-seconds .5 \
--stop-at-end \
--key \
--hide mouse,progress \
--file-idle-time 0 \
--max-files 0 \
@Frozenfire92
Frozenfire92 / reading_time.rb
Created January 14, 2016 00:37 — forked from zachleat/reading_time.rb
Read this in X minutes Liquid Filter Plugin (for Jekyll)
# Outputs the reading time
# Read this in “about 4 minutes”
# Put into your _plugins dir in your Jekyll site
# Usage: Read this in about {{ page.content | reading_time }}
module ReadingTimeFilter
def reading_time( input )
words_per_minute = 180
import Ember from 'ember';
export default Ember.Controller.extend({
appName:'Ember Twiddle'
});
/*
Basic Sprite Shader for aligning pixel art to the same grid, based on the Unity Sprite Shader.
Create one Material where you assign the same Pixels Per Unit value you use on your imported Sprites,
then reuse this Material on all appropriate Sprite Renderers.
(As far as I know there's no possiblity to get this value automatically.)
This is not for scaled or rotated artwork. If you need those features, look at low res render textures.
Use this however you want.
@Frozenfire92
Frozenfire92 / tmux.conf
Created December 13, 2016 14:10 — forked from spicycode/tmux.conf
The best and greatest tmux.conf ever
# 0 is too far from ` ;)
set -g base-index 1
# Automatically set window title
set-window-option -g automatic-rename on
set-option -g set-titles on
#set -g default-terminal screen-256color
set -g status-keys vi
set -g history-limit 10000