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
#Newbie programmer | |
def factorial(x): | |
if x == 0: | |
return 1 | |
else: | |
return x * factorial(x - 1) | |
print factorial(6) | |
#First year programmer, studied Pascal |
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
# -*- coding: utf-8 -*- | |
"""MyCompany Fabric script. | |
* Deploy code | |
* Set up a local development environment | |
There are two ways to deploy the myrepo code: | |
1. :func:`deploy` will do a full virtualenv installation/update and expand a | |
tarball of the specified git revision (defaults to HEAD) to a timestamped |
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
pool: www | |
process manager: dynamic | |
start time: 09/Jul/2014:21:09:41 -0400 | |
start since: 1843802 | |
accepted conn: 436469 | |
listen queue: 0 | |
max listen queue: 2 | |
listen queue len: 0 | |
idle processes: 598 | |
active processes: 2 |
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
- name: create postgres root user | |
postgresql_user: db=postgres | |
name={{ postgres_root_user }} | |
password={{ postgres_root_pass }} | |
role_attr_flags=SUPERUSER,LOGIN,CREATEDB,CREATEROLE,REPLICATION | |
when: datadir_path.stat.exists == false | |
- name: check postgres root user | |
postgresql_user: db=postgres | |
login_user={{ postgres_root_user }} |
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
z10n@tower Various Artists % tree -L 1 | |
. | |
├── 1992 - Macedonian Jazz | |
├── 1993 - Volume Eight - Volume [V08CD] | |
├── 1994 - Café del Mar - React [REACT CD 041] | |
├── 1994 - Jazz Legends - Verve [3145198242] | |
├── 1995 - Café del Mar, volumen dos - React [REACT CD 062] | |
├── 1995 - Jazz Legends - Giant Records [710457-1] | |
├── 1995 - Mind the Gap, Volume 5 - Gonzo Circus [GC011] | |
├── 1996 - Café del Mar, volumen tres - React [REACT CD 084] |
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
z10n@tower sorted % tree -L 3 | |
. | |
├── 1-9 | |
│ ├── 10,000 Maniacs | |
│ │ ├── 1989 - In My Tribe - Elektra [9 60738-2] | |
│ │ ├── 1993 - MTV Unplugged - Elektra Entertainment [61569-2] | |
│ │ └── 2004 - Campfire Songs The Popular, Obscure & Unknown Recordings (disc 1) - Elektra [R2 73900] | |
│ ├── 2 Many DJ's | |
│ │ └── 2002 - As Heard on Radio Soulwax, Part 2 - Play It Again Sam [PIAS] [PIASB 065 CD] | |
│ └── 4hero |
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
require "cjson" | |
-- Generic decoder for JSON logs. This will extract all JSON | |
-- keys and add them to the `Fields` variable of the created | |
-- Heka message. | |
-- | |
-- Example use: | |
-- | |
-- [NginxJsonLogDecoder] | |
-- type = "SandboxDecoder" |
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
[root@ad-main ~]# systemctl status channels | |
channels.service - channels | |
Loaded: loaded (/etc/systemd/system/channels.service; enabled) | |
Active: failed (Result: exit-code) since Wed 2014-10-01 11:18:28 EDT; 1 weeks 1 days ago | |
Process: 11352 ExecStart=/usr/local/bin/channels (code=exited, status=2) | |
Main PID: 11352 (code=exited, status=2) | |
CGroup: /system.slice/channels.service | |
Oct 01 11:18:06 ad-main channels[11352]: TARG-IGNORE-PREF: !tube_sponsor | |
Oct 01 11:18:06 ad-main channels[11352]: [33 52 50 54 124 49 49 48 48 124 57 50 48 57 54 57 124 54 56 51 13 10 13 10 109 82 65 142 219 48 12 124 75 15 241 197 216 69 28 111 55 221 131 14... 98 230 69 29 |
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
[root@um-1913 ~]# mdadm -D /dev/md2 | |
/dev/md2: | |
Version : 1.2 | |
Creation Time : Sat Oct 11 00:53:24 2014 | |
Raid Level : raid6 | |
Array Size : 19386378240 (18488.29 GiB 19851.65 GB) | |
Used Dev Size : 1938637824 (1848.83 GiB 1985.17 GB) | |
Raid Devices : 12 | |
Total Devices : 12 | |
Persistence : Superblock is persistent |
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
-- This Source Code Form is subject to the terms of the Mozilla Public | |
-- License, v. 2.0. If a copy of the MPL was not distributed with this | |
-- file, You can obtain one at http://mozilla.org/MPL/2.0/. | |
require "math" | |
require "string" | |
local alert = require "alert" | |
local message_variable = read_config("message_variable") or error("must specify a 'message_variable'") | |
local max_items = read_config("max_items") or 25000 |
OlderNewer