Skip to content

Instantly share code, notes, and snippets.

@ccprog
ccprog / msgmerge.js
Created Jun 3, 2014
A grunt task for gettext msgmerge
View msgmerge.js
module.exports = function(grunt) {
// use `msginit -i my-text.pot -l <ll_CC> -o my-text-<ll_CC>.po` to start new translations
grunt.registerMultiTask('msgmerge', function() {
var options = this.options({
text_domain: 'messages',
template: './',
});
@ccprog
ccprog / XletSettingsWidgets.patch
Last active May 16, 2016
Cinnamon applet settings: display a setting value by choosing an option
View XletSettingsWidgets.patch
--- /usr/share/cinnamon/cinnamon-settings/bin/XletSettingsWidgets.py
+++ /usr/share/cinnamon/cinnamon-settings/bin/XletSettingsWidgets_live_update.py
@@ -50,6 +50,7 @@
self.handler = self.file_monitor.connect("changed", self.on_file_changed)
self.file_changed_timeout = None
self.resume_timeout = None
+ self.monitor_exeption = None
def create(self, key, setting_type, uuid):
try:
@ccprog
ccprog / SassMeister-input.scss
Created Aug 28, 2016
Generated by SassMeister.com.
View SassMeister-input.scss
// ----
// Sass (v3.4.21)
// Compass (v1.0.3)
// ----
*:link {
&:visited {
*:selected & { color: red; }
}
}
@ccprog
ccprog / SassMeister-input.scss
Created Aug 28, 2016
Generated by SassMeister.com.
View SassMeister-input.scss
// ----
// libsass (v3.3.6)
// ----
*:link {
&:visited {
*:selected & { color: red; }
}
}
@ccprog
ccprog / render-assets.sh
Created Sep 7, 2016
Optimized asset script for Mint-Y-theme, GTK3 variant
View render-assets.sh
#! /bin/bash
INKSCAPE="/usr/bin/inkscape"
OPTIPNG="/usr/bin/optipng"
SRC_FILE="assets.svg"
ASSETS_DIR="assets"
INDEX="assets.txt"
TEMP_INDEX="assets.tmp"
@ccprog
ccprog / hover.svg
Created Aug 30, 2017
a strange animation behavior
View hover.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View resource.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@ccprog
ccprog / reversal.js
Created Sep 2, 2020
add path direction reversal to pathfit
View reversal.js
const Parser = require('./pathParser.js');
const Formatter = require('./formatter.js');
function parse (str) {
const sequence = [];
const parser = new Parser();
const splited = parser.commands(str);
if (splited.length && !splited[0].match(/m/i)) {
@ccprog
ccprog / dev-badge.svg
Last active Oct 22, 2020
dev.io icon Original
View dev-badge.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@ccprog
ccprog / dev-badge-a.svg
Created Oct 22, 2020
dev.io icon with my handish optimization
View dev-badge-a.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.