#The power of z
Do you spend lots of time doing things like this?
cd this/is/the/path/that/i/want/so/i/type/it/all/out/to/get/whereiwant
With z, you could just do this:
// A repository. | |
public interface IPurchaseOrderRepository | |
{ | |
PurchaseOrder Get(string id); | |
// The commit method would likely be moved to a Unit of Work managed by infrastructure. | |
void Commit(); | |
} | |
// A marker interface for a domain event. | |
public interface IDomainEvent { } |
// set-up a connection between the client and the server | |
var socket = io.connect(); | |
// let's assume that the client page, once rendered, knows what room it wants to join | |
var room = "abc123"; | |
socket.on('connect', function() { | |
// Connected, let's sign-up for to receive messages for this room | |
socket.emit('room', room); | |
}); |
#!/bin/bash | |
# Docker doesn't have a great way to set runtime environment variables, | |
# so use this script to prepare the execution environnment for later processes. | |
export SQLALCHEMY_DATABASE_URI="postgresql://${DB_PORT_5432_TCP_ADDR}:5432/database_name" | |
# Execute the commands passed to this script | |
# e.g. "./env.sh venv/bin/nosetests --with-xunit | |
exec "$@" |
#The power of z
Do you spend lots of time doing things like this?
cd this/is/the/path/that/i/want/so/i/type/it/all/out/to/get/whereiwant
With z, you could just do this:
# Compiled source # | |
################### | |
*.com | |
*.class | |
*.dll | |
*.exe | |
*.o | |
*.so | |
# Packages # |
import java.io.FileDescriptor; | |
import java.io.FileOutputStream; | |
import java.io.IOException; | |
import java.io.OutputStream; | |
import java.io.PrintStream; | |
public class HelloWorld{ | |
private static HelloWorld instance; | |
public static void main(String[] args){ | |
instantiateHelloWorldMainClassAndRun(); |
# On slow systems, checking the cached .zcompdump file to see if it must be | |
# regenerated adds a noticable delay to zsh startup. This little hack restricts | |
# it to once a day. It should be pasted into your own completion file. | |
# | |
# The globbing is a little complicated here: | |
# - '#q' is an explicit glob qualifier that makes globbing work within zsh's [[ ]] construct. | |
# - 'N' makes the glob pattern evaluate to nothing when it doesn't match (rather than throw a globbing error) | |
# - '.' matches "regular files" | |
# - 'mh+24' matches files (or directories or whatever) that are older than 24 hours. | |
autoload -Uz compinit |
Veamos un flujo de trabajo con Git para gestionar y aprobar un Pull Request (PR) en un repositorio remoto compartido. El flujo de trabajo se ha comprobado que funciona correctamente en repositorios remotos gestionados en Bitbucket.
Suponemos un equipo formado por 3 desarrolladores (Ana, Lucía y Carlos) que están trabajando sobre un repositorio compartido utilizando el flujo de trabajo denominado Gitflow (ver el post de Vicent Driessen). En la rama develop
se integran las features que se van desarrollando en ramas independientes.
Se ha definido la política de que antes de integrar una rama de característica se debe realizar un Pull Request en Bitbucket y algún otro miembro del equipo debe comprobar su funcionamiento y dar el visto bueno. La integración la realizará el mismo desarrollador que ha creado el Pull Request. Aunque Bitbucket proporciona la opción de cerrar el PR desde la interfaz web, utilizaremos comandos Git en e
Academic/Background | |
------------------------------------------------------------------------------------------------------------ | |
Software Architecture, Perspectives on an emerging discipline - Mary Shaw, David Garlan | |
Introduction / Practice within Business | |
------------------------------------------------------------------------------------------------------------ | |
Software Architecture in Practice - Len Bass, Paul Clements, Rick Kazman | |
In depth handbook for reaching requirements | |
------------------------------------------------------------------------------------------------------------ |
// RSA with node-forge | |
"use strict"; | |
// npm install node-forge | |
const forge = require("node-forge"); | |
new Promise((f, r) => forge.pki.rsa.generateKeyPair( | |
2048, (err, pair) => err ? r(err) : f(pair))) | |
.then(keypair => { | |
const priv = keypair.privateKey; |