Skip to content

Instantly share code, notes, and snippets.

View josdem's full-sized avatar
🤖
Moving to Google Cloud

Jose Morales josdem

🤖
Moving to Google Cloud
View GitHub Profile
@josdem
josdem / Vim
Last active March 25, 2016 14:36
// Saving file as root
w !sudo tee %
// Setting look and feel
:set syntax=apache
//Move NERDTree vertical panel to the left
Ctrl w
>
@josdem
josdem / Hugo
Last active March 21, 2018 21:23
// Run hugo as localhost with hugo-artist-theme and automatic reload
hugo server --theme=hugo-artists-theme --buildDrafts
// Creating new markdown content
hugo new jmetadata/tutorials.md
or
hugo new techtalk/java/executors.md
// Build hugo in the server
hugo --baseUrl=http://josdem.io/ --theme=hugo-artists-theme --buildDrafts
@josdem
josdem / tmux
Last active April 15, 2016 15:09
set -g prefix C-a ### Cambiando prefijos
set -sg escape-time 1 ### Cambiando el delay de los commandos
set -g base-index 1 ### Cambiando la numeracion de las ventanas
setw -g pane-base-index 1 ### Cambiando la numeracion de los paneles
bind C-a send-prefix ### Compartiendo el prefijo con otras aplicaciones
bind r source-file ~/.tmux.conf \; display "Reloaded!" ### Asignando comando para la recarga del archivo de configuracion
bind | split-window -h ### Asignando comando para dividir el panel de manera vertical
bind - split-window -v ### Asignando comando para dividir el panel de manera horizontal
@josdem
josdem / sts.desktop
Last active January 5, 2020 13:09
Set sts icon in ubuntu
[Desktop Entry]
Type=Application
Name=sts
Comment=Spring Tool Suite
Icon=/home/josdem/STS/sts-3.7.3.RELEASE/icon.xpm
Exec=/home/josdem/STS/sts-3.7.3.RELEASE/STS
Terminal=false
Categories=Development;IDE;Java;
StartupWMClass=STS
//Search and replace a word in a directory
Ctrl + Shift + f
//Delete a line
Ctrl + Shift + k
//Move a line up
Ctrl + Shift + UP
//Replace a word in a text
@josdem
josdem / Httpie
Last active November 19, 2015 17:25
//POST jugoterapia josdem.io
http --form POST http://jugoterapia.josdem.io/jugoterapia-server/beverage/beverages categoryId=1
//GET with query params
http GET http://localhost:8080/sepomex/show cp==01270
@josdem
josdem / Tools
Last active October 17, 2015 19:43
//Copy in clipboard
xclip -sel clip < ~/.ssh/id_rsa.pub
@josdem
josdem / Liquibase
Last active November 4, 2015 18:46
//Generate a new changelog
dbm-generate-changelog changelog.groovy
//Generate a changelog
dbm-gorm-diff add-telephone.groovy --add
//Update database schema
dbm-update
//Run specific test
grails test-app -unit com.modulus.uno.UserServiceSpec
//Run all test
grails test-app
//Create controller and views from a domain class
grails generate-all com.modulus.uno.Telephone
//Create a Service
@josdem
josdem / SDK
Created December 18, 2015 01:16
//Install specific grails version
sdk install grails 3.0.9
//List grails versions
sdk list grails