This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun duplicate-current-line-or-region (arg) | |
"Duplicates the current line or region ARG times. | |
If there's no region, the current line will be duplicated. However, if | |
there's a region, all lines that region covers will be duplicated." | |
(interactive "p") | |
(let (beg end (origin (point))) | |
(if (and mark-active (> (point) (mark))) | |
(exchange-point-and-mark)) | |
(setq beg (line-beginning-position)) | |
(if mark-active |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <unistd.h> | |
#include <string.h> | |
#include <glib.h> | |
#include <libsoup/soup.h> | |
#include <libsoup/soup-auth.h> | |
static char* django_get_csrftoken_from_body(SoupMessage *msg) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
makemessagesjs: | |
grunt nggettext_extract; \ | |
export PO_FILE=locale/fr/LC_MESSAGES/angular.po; \ | |
export POT_FILE=$${PO_FILE}t; \ | |
[ ! -f $$PO_FILE ] && msginit -i $$POT_FILE -o $$PO_FILE || msgmerge --update $$PO_FILE $$POT_FILE; \ | |
rm $$POT_FILE; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* global module */ | |
module.exports = function(grunt) { | |
'use strict'; | |
grunt.loadNpmTasks('grunt-angular-gettext'); | |
grunt.initConfig({ | |
nggettext_extract: { | |
ops: { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function disable_a_moment(o) { | |
o.disabled = true; | |
o.value = o.value + "…"; | |
setTimeout(function() { | |
o.disabled = false; | |
o.value = o.value.substr(0, o.value.length - 1); | |
}, 5000); | |
} |
NewerOlder