Skip to content

Instantly share code, notes, and snippets.

Yo-An Lin c9s

Block or report user

Report or block c9s

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@c9s
c9s / m4a_to_mp3.sh
Created May 13, 2009
this script convert m4a audio file to mp3 file
View m4a_to_mp3.sh
#!/bin/bash
input=$1
if [[ -z "$input" ]] ; then
echo "Usage: $0 [m4a filepath]"
exit
fi
if [[ -z $(which faad) ]] ; then
echo "Can not found faad , please install it"
View svk-filetype-plugin.vim
" SVK VIM Plugin Improve
" Author: Cornelius (c9s) <cornelius.howl (at) gmail.com>
" Version: 0.11
" original version is from Olekasandr Tymoshenko
" ------------------------------
" Language: SVK commit file
" Maintainer: Oleksandr Tymoshenko <gonzo@bluezbox.com>
" URL: http://gonzo.kiev.ua/files/vim/ftplugin/svk.vim
" Revision: $Id$
View install-cpan.vim
nmap <C-x><C-i> :call InstallCPANModule()<CR>
function! InstallCPANModule()
let cw = expand('<cWORD>')
let cw = substitute( cw , ";$" , "" , "g" )
let cw = substitute( cw , "['\"]" , "" , "g" )
echo "Installing CPAN Module: " . cw . "\n"
silent exec "!cpanp i " . cw . " >& /dev/null"
echo "Done\n"
endfunction
View switch-trunk-branch.sh
#!/bin/bash
# simple script for switching directory between branches and trunk.
#
# svnb/svnt directory switch function works for current path like
# /home/work/project/trunk
# /home/work/project/branches
# /home/work/project/branches/feature
#
# goto branch:
# svnb [branch-name]
View paste.perl
Index: lib/Jifty/Web.pm
===================================================================
--- lib/Jifty/Web.pm (revision 6773)
+++ lib/Jifty/Web.pm (working copy)
@@ -995,6 +995,11 @@
%results = ($only_moniker => $results{$only_moniker}) if $only_moniker;
return unless grep {$_->$type()} values %results;
+
+ # * skip render notification message if we are in in fragments, the notification
View paste.perl
WARN - at /usr/local/lib/perl5/site_perl/5.8.8/Jifty/DBI/Schema.pm line 404
Jifty::DBI::Schema::_init_column_for('Jifty::DBI::Column=HASH(0xa224bf8)', 'AIINK::Model::OrderItem') called at /usr/local/lib/perl5/site_perl/5.8.8/Jifty/DBI/Schema.pm line 306
Jifty::DBI::Schema::_init_column('Jifty::DBI::Column=HASH(0xa224bf8)') called at /usr/local/lib/perl5/site_perl/5.8.8/Jifty/DBI/Schema.pm line 226
Jifty::DBI::Schema::__ANON__() called at /usr/local/lib/perl5/site_perl/5.8.8/Jifty/DBI/Record.pm line 97
Jifty::DBI::Record::import('AIINK::Record', '-base', 'CODE(0xa21a148)') called at /home/sites/AIINK/lib/AIINK/Model/OrderItem.pm line 55
AIINK::Model::OrderItem::BEGIN() called at /home/sites/AIINK/lib/AIINK/Model/OrderItem.pm line 55
eval {...} called at /home/sites/AIINK/lib/AIINK/Model/OrderItem.pm line 55
View paste.perl
Index: share/plugins/Jifty/Plugin/SinglePage/web/static/js/singlepage/spa.js
===================================================================
--- share/plugins/Jifty/Plugin/SinglePage/web/static/js/singlepage/spa.js (revision 6773)
+++ share/plugins/Jifty/Plugin/SinglePage/web/static/js/singlepage/spa.js (working copy)
@@ -7,18 +7,49 @@
}
});
+//
+// first load.
View paste.perl
; Script generated by the HM NIS Edit Script Wizard.
; HM NIS Edit Wizard helper defines
!define PRODUCT_NAME "Qt Runtime Installer"
!define PRODUCT_VERSION "1.0"
!define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
!define PRODUCT_UNINST_ROOT_KEY "HKLM"
!define PRODUCT_STARTMENU_REGVAL "NSIS:StartMenuDir"
; MUI 1.67 compatible ------
View gist:186056
use warnings;
use strict;
use threads qw(yield);
# require Vimana::VimOnline::ScriptPage;
sub get_cache {
use Cache::Memory;
return Cache::Memory->new(
namespace => 'MyNamespace',
View gist:199086
#!perl
# get perl function list
open(FH, '-|', qq|podselect -section 'DESCRIPTION/Alphabetical Listing of Perl Functions' pod/perlfunc.pod| );
my @func ;
my $inline = 0;
while( <FH> )
{
if( /^=over/ ) {
$inlist++;
}
You can’t perform that action at this time.