Used font: http://stuff.dasprids.de/fonts/ubuntumono-powerline.tar.bz2
You can patch any font yourself with the fontpatcher: https://github.com/Lokaltog/vim-powerline/tree/develop/fontpatcher
| #!/bin/sh | |
| echo | |
| exec powershell.exe -ExecutionPolicy RemoteSigned -File '.\.git\hooks\pre-commit-hook.ps1' | |
| exit |
| #!/usr/bin/perl | |
| # -- | |
| # bin/otrs.AddCustomer2Group.pl - Add Customer to a Group | |
| # Copyright (C) 2001-2013 OTRS AG, http://otrs.com/ | |
| # -- | |
| # This program is free software; you can redistribute it and/or modify | |
| # it under the terms of the GNU AFFERO General Public License as published by | |
| # the Free Software Foundation; either version 3 of the License, or | |
| # any later version. | |
| # |
Used font: http://stuff.dasprids.de/fonts/ubuntumono-powerline.tar.bz2
You can patch any font yourself with the fontpatcher: https://github.com/Lokaltog/vim-powerline/tree/develop/fontpatcher
| # create systemd service file for rails 2.3.x startup | |
| [Unit] | |
| Description=rails 2.3.x web server | |
| [Service] | |
| Type=simple | |
| RemainAfterExit=yes | |
| User=username | |
| PIDFile=/home/username/WEBSERVER/tmp/pids/thin.pid | |
| WorkingDirectory=/home/username/WEBSERVER |
| #!/usr/bin/env ruby | |
| pid = Kernel.fork do | |
| `#{ARGV.join(" ")}` | |
| exit | |
| end | |
| trap(:CHLD) do | |
| print "\n" | |
| exit |
| <?php | |
| /* | |
| OCP - Opcache Control Panel (aka Zend Optimizer+ Control Panel for PHP) | |
| Author: _ck_ (with contributions by GK, stasilok) | |
| Version: 0.1.7 | |
| Free for any kind of use or modification, I am not responsible for anything, please share your improvements | |
| * revision history | |
| 0.1.7 2015-09-01 regex fix for PHP7 phpinfo | |
| 0.1.6 2013-04-12 moved meta to footer so graphs can be higher and reduce clutter |
| This configuration is a working copy which I have tested on Apache 2.2.x and 2.4.x | |
| I highly recommend you use this version of mod_fastcgi as it works with Apache 2.4.x, fastcgi.com version does not! | |
| https://github.com/ByteInternet/libapache-mod-fastcgi | |
| The fastcgi.com version is 2.4.6, the version I am recommending registers as 2.4.7 | |
| To patch mod_fastcgi for use with Apache 2.4.x look at the debian/patches folder. It's not specific to Debian OS so don't let that fool you. I personally use Archlinux. | |
| Of course to compile mod_fastcgi: |
| -- show running queries (pre 9.2) | |
| SELECT procpid, age(clock_timestamp(), query_start), usename, current_query | |
| FROM pg_stat_activity | |
| WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%' | |
| ORDER BY query_start desc; | |
| -- show running queries (9.2) | |
| SELECT pid, age(clock_timestamp(), query_start), usename, query | |
| FROM pg_stat_activity | |
| WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%' |
| #!/usr/bin/php | |
| <?php | |
| /** | |
| * .git/hooks/pre-commit | |
| * | |
| * This pre-commit hooks will check for PHP error (lint), and make sure the code | |
| * is PSR compliant. | |
| * | |
| * Dependecy: PHP-CS-Fixer (https://github.com/fabpot/PHP-CS-Fixer) | |
| * |
| MOCKING DATABASE OPERATIONS | |
| =========================== | |
| In our webreg example, we refactored some code so that we could | |
| pass in our database object instead of creating it inside. Let's | |
| push that further and show a slightly advanced usage of a mock | |
| object. | |
| So let's rework our Franchise test to use a mocked database connection. |