Thursday, July 30, 2009

Subversion

Crear subdirectorio
svn mkdir https://.../diegoandresalvarez/LaTeX/svn/libro_solidos -m "Creando subdirectorio libro_solidos"

Importar
svn import ~/Desktop/libro_solidos/ https://.../diegoandresalvarez/LaTeX/svn/libro_solidos -m "Initial import"

Checkout: Aquí se creará un subdirectorio libro_solidos que contiene los archivos que están adentro
svn checkout https://free1.projectlocker.com/diegoandresalvarez/LaTeX/svn/libro_solidos
login>> diegotorquemada@gmail.com
pass>> ya lo sabe

Exportar (sacar copia sin los .svn)
svn export ~/Desktop/libro_solidos/ https://.../diegoandresalvarez/LaTeX/svn/libro_solidos

Lista de proyectos
svn list --verbose https://.../diegoandresalvarez/LaTeX/svn/

Remover la parte de archivos ejecutables... parado en el padre de libro_solidos haga
svn propdel svn:executable -R libro_solidos

Actualiza copia actual
svn update

Commit a change
svn commit -m "Mensaje"

Agregar y borrar archivos
svn add filename
svn delete filename

Copiar y mover archivos
svn copy original destino
svn move oldposition newposition

Compara actual con repositorio
svn status

Mirar cierta versión de un archivo
ej svn cat -r 19 foo.c

Comparando copia actual con repositorio
svn diff librosolidos.kilepr | kompare -o -
svn diff | kompare -
svn diff |iconv -f ISO_8859-1 -t utf-8 | kompare -o -
svn diff -r 143 energia.tex Compara la copia de trabajo actual con version 143
svn diff --diff-cmd diff > diferencia.txt

http://en.wikibooks.org/wiki/LaTeX/Collaborative_Writing_of_LaTeX_Documents
http://www.tug.org/pracjourn/2007-3/skiadas-svn/skiadas-svn.pdf
http://www.tug.org/pracjourn/2007-3/kalderon-svnmulti/kalderon-svnmulti.pdf


At the end of the [helpers] section in ~/.subversion/config add (tomado de http://brainvisa.info/repository.html)

editor-cmd = kate
diff-cmd = kompare_svn
diff3-cmd = kdiff3_svn
merge-tool-cmd = kdiff3_svn


Here kompare_svn is the script (base their mine merged)

#!/bin/sh
exec kompare "$6" "$7"

And kdiff3_svn is the script

#!/bin/sh

if [ "$#" != "3" ]; then
if [ "$#" != "4" ]; then
outfile=`mktemp`
res=0
# kdiff3 --L1 "$4" --L2 "$6" --L3 "$8" -out "${outfile}" "$9" "${10}" "${11}" && cat "${outfile}" || res=1
kdiff3 -out "${outfile}" "${10}" "${11}" "$9" && cat "${outfile}" || res=1
if [ -f "${outfile}" ]; then
rm -f "${outfile}"
fi
if [ -f "${outfile}.orig" ]; then
rm -f "${outfile}.orig"
fi
exit $res
fi
fi
if [ "$#" -gt 3 ]; then
exec kdiff3 -out "$4" "$1" "$2" "$3"
else
exec kdiff3 "$1" "$2" "$3"
fi


Alternativamente
#!/bin/sh
kdiff3 -m $1 $2 $3 -o $4 1>&2


Remember to make both scripts executable


En caso de conflict resolution haga lo siguiente:
http://chestofbooks.com/computers/revision-control/subversion-svn/Postponing-Conflict-Resolution-Tour-Cycle-Resolve-Pending.html

svn resolved torsion.tex

No comments: