Skip to content

Instantly share code, notes, and snippets.

View dpalomar's full-sized avatar

David Palomar dpalomar

View GitHub Profile
@dpalomar
dpalomar / .gitattributes
Created April 8, 2016 12:43
Fixing CRLF with gitattributes
From this [issue](https://github.com/puphpet/puphpet/issues/1025#issuecomment-157059174):
I know that this issue is closed, but as I spent a lot of time to understand what was going on, I made some researches and I can explain why this happen, and you can fix it.
Using git config core.autocrlf true can help, but not on a multi-developpers project.
This command has to be the same on each developper machine, and that's not always the case.
You have to use the .gitattributes provided in the puphpet archive and edit it as follow (carefull, this file need to be in your project root)
You also need to use an IDE that allow you to save/edit files as LF (like phpstorm). You can check the type of the file in the bottom right corner, in the status bar (you'll see LF or CRLF while a file is opened)
@dpalomar
dpalomar / settings.xml
Created November 4, 2015 11:38
Configuracion settings.xml para gh-pages
<settings>
<servers>
<server>
<id>github</id>
<username>changeme</username>
<password>changeme</password>
</server>
</servers>
</settings>
@dpalomar
dpalomar / Operaciones-Git
Last active January 29, 2019 09:39 — forked from jelcaf/Operaciones-Git
Git Tips - Mini-trucos de Git para facilitarme la tarea
#############################################
# Push de la rama actual
git push origin $rama_actual
#############################################
# Volver a un commit anterior, descartando los cambios
git reset --HARD $SHA1
#############################################
# Ver y descargar Ramas remotas
@dpalomar
dpalomar / TIW-install-linux.sh
Last active September 15, 2015 12:12
TIW maven archetype automatically install on linux
#!/bin/sh
# This script allows to install the maven archetype for TIW subject.
# Use: wget -qO- https://goo.gl/NEIuFi | sh
# or curl -sSL https://goo.gl/NEIuFi | sh
echo "**** THIS WILL INSTALL THE ARCHETYPE, PLEASE BE PATIENT ****"
echo "**** You need git and maven instaled and a live connection ****"
echo "**Removing last version**"
rm -rf ~/.m2/repository/es/
echo "1- Download from git"
echo "2- installing with maven "