"Any fool can know. The point is to understand" - Albert Einstein
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
using System; | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
Console.WriteLine(new Program().M()); | |
} | |
bool M() |
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
First we create a class & write the following code: | |
public class StudentMethod | |
{ | |
public int Roll { get; set; } | |
public string Name { get; set; } | |
} |
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
#!/usr/bin/env bash | |
# Add a subtree from a repository | |
# | |
# @param 1 - URL of repository | |
# @param 2 - prefix for repository directory (optional) | |
add() | |
{ | |
local NAME=${1##*/} | |
NAME=${NAME%.*} |
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
(See http://xprogramming.com/articles/deliver-working-software-frequently/ and http://leanblitzconsulting.com/14-principles-of-the-toyota-way/) | |
Are you not getting everything you take on finished? Then take on less. | |
"Use pull systems to avoid overproduction" | |
Are there defects in your code? Then test it sooner and better. Try pair programming. | |
"Level out the workflow. Work like the tortoise, not the hare" and “Use visual controls so no problems are hidden.” | |
Is your code hard to work with? Then refactor it as you go. | |
"Build a culture of stopping to fix problems, to get quality right the first time" |
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
# basic command | |
uname -a | |
cat /etc/proc/version | |
# zip / unzip | |
tar -czvf shared.tar.gz shared | |
tar -tzvf shared.tar.gz | |
tar -xzvf shared.tar.gz | |
gzip 1.js | |
gzip -d *.gz |
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
<!DOCTYPE html> | |
<html lang="en" > | |
<head> | |
<meta charset="UTF-8" /> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Sistema de Cadastro - São Judas</title> | |
<meta name="description" content="Cadastro CISE - São Judas" /> | |
<meta name="keywords" content="page transition, Sao Judas, website, cadastro, css3, jquery" /> | |
<meta name="author" content="Leandro Cubas" /> |
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
Doing it this way means you are loading the app directly from a custom boot script. I also specified a custom environment and Gemfile: | |
RAILS_ENV=lean_development BUNDLE_GEMFILE=LeanGemfile bundle exec script/lean |
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
/** | |
* lsauer, 2013 | |
* Lean handler for exception reporting; stdout is set by default to console.log | |
* @param {exc} exc an Exception instance of Error, containing a message and stack property | |
* @param {exc} stdOut A variadic function for error reporting. By default: console.log | |
* @return undefined | |
*/ | |
var exceptionHandler = function(exc, stdOut){ | |
var stdOut = stdOut || function() { console.log.apply(console, arguments) }; | |
if(stdOut instanceof Function){ |