rails generate scaffold Post name:string title:string content:text
rails generate model Post title:string body:text published:boolean
def clean_inactive_devices(f): | |
""" | |
This turns as inactive to the unused devices | |
""" | |
@wraps(f) | |
def decorated(*args, **kwargs): | |
# process anythin BEFORE | |
results, device_tokens = f(*args, **kwargs) | |
# process anythin AFTER |
Whether you're trying to give back to the open source community or collaborating on your own projects, knowing how to properly fork and generate pull requests is essential. Unfortunately, it's quite easy to make mistakes or not know what you should do when you're initially learning the process. I know that I certainly had considerable initial trouble with it, and I found a lot of the information on GitHub and around the internet to be rather piecemeal and incomplete - part of the process described here, another there, common hangups in a different place, and so on.
In an attempt to coallate this information for myself and others, this short tutorial is what I've found to be fairly standard procedure for creating a fork, doing your work, issuing a pull request, and merging that pull request back into the original project.
Just head over to the GitHub page and click the "Fork" button. It's just that simple. Once you've done that, you can use your favorite git client to clone your repo or j
Generate the kubeconfig file for your cluster using the Kubeconfig File
button in the Cluster view of your cluster.
Save the generated file as $HOME/.kube/config
and run kubectl get nodes
to verify it works.
<VirtualHost *:80> | |
ServerName DOMAIN | |
ServerAdmin support@xiberty.com | |
DocumentRoot /var/www/PROJECT_FOLDER | |
ServerAlias www.DOMAIN | |
<Directory /var/www/PROJECT_FOLDER/> | |
Options +FollowSymlinks | |
AllowOverride All | |
Require all granted |
server { | |
listen 80; | |
root /var/www/angular.xiberty.com/dist; | |
index index.php index.html index.htm; | |
server_name angular.xiberty.com; | |
access_log /var/www/angular.xiberty.com/nginx-access.log; | |
error_log /var/www/angular.xiberty.com/nginx-error.log; |
server { | |
listen 80; | |
root path/to/site; | |
index index.php index.html index.htm; | |
server_name DOMAIN; | |
access_log path/to/site/var/log/nginx-access.log; | |
error_log path/to/site/var/log/nginx-error.log; |
package com.xiberty.jiwaki.agenda.fragments.events; | |
import android.app.ProgressDialog; | |
import android.os.Bundle; | |
import android.support.design.widget.TabLayout; | |
import android.support.v4.app.Fragment; | |
import android.support.v4.view.ViewPager; | |
import android.view.LayoutInflater; | |
import android.view.MenuItem; | |
import android.view.View; |
Git for Windows viene por defecto con "Git Bash" esta terminal tiene las utilidades más comunes de Linux, sin embargo no tiene todos los comandos, pero es muy sencillo agregar nuevos comandos obviamente simpre que haya un binario instalador del comando para Windows.
La idea es basicamente es el directorio C:\Program Files\Git\mingw64\
es tu directorio raiz /
para Git Bash (Nota: dependerá de como lo hayas instalado, el directorio podríá ser diferente. Dale click derecho en el icono de Git Bash
y abre la ubicacion del archivo para saber la ruta de instalación. Find it by using pwd -W
).
Ya en la carpeta mingw64
encontraras una estructura similar a la estructura de carpetas de linux (bin
, etc
, lib
, etc).
Para instalar alguna utilidad, por ejemplo wget
, deberas descargar el binario de esta utilidad, renombrarla con el nombre del comando en este caso wget.exe y copiarla dentro de la carpeta
bin
en
server { | |
charset utf-8; | |
#listen <YOUR_IP>:80; | |
server_name <YOUR_DOMAIN> www.<YOUR_DOMAIN>; | |
root /PATH/TO/YOUR/PRESTASHOP/INSTALLATION; | |
index index.php; | |
access_log /var/log/nginx/domains/<YOUT_DOMAIN>.log combined; |