diff --git a/skeleton/markdown.html b/skeleton/markdown.html new file mode 100644 index 0000000000000000000000000000000000000000..f5e374d93a8ac445cb90a2345aa5bcd0fd022e3c --- /dev/null +++ b/skeleton/markdown.html @@ -0,0 +1,28 @@ + + + + + + + + + + + +
+

Installation

+

To install Git:

+
apt-get install git
+

Now you can do the following:

+ +
+ + diff --git a/skeleton/markdown.xcf b/skeleton/markdown.xcf new file mode 100644 index 0000000000000000000000000000000000000000..1b617117e9a0eea40e4e086de76f5051bf52604c Binary files /dev/null and b/skeleton/markdown.xcf differ diff --git a/skeleton/skeleton.tex b/skeleton/skeleton.tex index 4e24a08f84350f97123d8e020209d3059bc89c51..65a4e3f9bd246b1e328da088bc3b3aa549998aab 100644 --- a/skeleton/skeleton.tex +++ b/skeleton/skeleton.tex @@ -54,10 +54,10 @@ \begin{pframe} Usage: \begin{itemize} - \item Make a \emph{fork} (copy) of the skeleton project. + \item Make a clone of the skeleton project. \item Rename the project. - \item Clone your project. - \item Start working with it. + \item Create a new project on the server. + \item Change the remote \bt{origin} to your new project. \end{itemize} \bigskip \pause @@ -76,35 +76,6 @@ \permfoot{https://git.lumc.nl/lgtc-bioinformatics/project-skeleton} \end{pframe} -%\subsection{Forking} -%\begin{pframe} -% Make a new analysis project. -% \begin{itemize} -% \item Go to the ``Project skeleton'' project page on our GitLab server. -% \item Click ``Fork'' to fork it to a new project. -% \item Go to ``Settings'' to rename the new project. -% \begin{itemize} -% \item Change both the project as well as the repository path. -% \end{itemize} -% \end{itemize} -% -% \vfill -% \permfoot{https://git.lumc.nl/lgtc-bioinformatics/project-skeleton} -%\end{pframe} - -%\subsection{Configuration} -%\begin{pframe} -% Configure your project. -% \begin{itemize} -% \item Choose to make your project public or not. -% \begin{itemize} -% \item Public by default. -% \item Public really means public. -% \end{itemize} -% \item Add the people that work on this project. -% \end{itemize} -%\end{pframe} - \section{Project structure} \subsection{Global overview} \begin{pframe} @@ -117,10 +88,35 @@ \end{itemize} \bigskip - Ideally, every directory in the project has a \bt{README} file. + Ideally, every directory in the project has a \bt{README.md} file. +\end{pframe} + +\subsection{Markdown files} +\begin{pframe} + \begin{lstlisting}[language=none, caption=Markdown snippet.] + # Installation + + To install [Git](http://www.git-scm.com/): + + apt-get install git + + Now you can do the following: + + - Make a new repository with `git init`. + - Clone an existing repository with `git clone`. + \end{lstlisting} +\end{pframe} + +\begin{pframe} + \begin{figure}[] + \begin{center} + \includegraphics[width=\textwidth]{markdown} + \end{center} + \caption{Rendered markdown page.} + \end{figure} \end{pframe} -\subsection{The toplevel ``README'' file} +\subsection{The toplevel ``README.md'' file} \begin{pframe} This file contains general information about the project, for example: \begin{itemize} @@ -148,7 +144,7 @@ Used to store all raw data. \bigskip - The \bt{README} contains: + The \bt{README.md} contains: \begin{itemize} \item Description of the delivered data. \begin{itemize} @@ -174,6 +170,7 @@ \begin{pframe} All analysis related files are stored here: \begin{itemize} + \item Symlinks to the actual data. \item Run scripts. \item Make files. \item Result files. @@ -181,7 +178,7 @@ \bigskip Try to separate self-contained parts of the analysis in their own - subdirectories and document dependencies in a \bt{README} file. + subdirectories and document dependencies in a \bt{README.md} file. \begin{itemize} \item Normal data analysis. \item $k$-mer analysis. @@ -263,6 +260,20 @@ \end{lstlisting} \end{pframe} +\subsection{Modifying files} +\begin{pframe} + Sometimes we need to change the content of a file. + \bigskip + + \begin{lstlisting}[language=none, caption=Unlocking a file.] + $ git annex edit + unlock (copying...) ok + \end{lstlisting} + \bigskip + + You can use \bt{git annex add} when you are done. +\end{pframe} + \subsection{Removing files} \begin{pframe} As long as there are enough copies available, you can remove files. @@ -304,6 +315,29 @@ \end{lstlisting} \end{pframe} +\subsection{Cleaning your repository} +\begin{pframe} + You can clean your repository with one command. + \bigskip + + \begin{lstlisting}[language=none, caption=Remove untracked files.] + $ git clean -f -x + \end{lstlisting} + + \begin{table}[] + \begin{center} + \begin{tabular}{ll} + option & description\\ + \hline + \bt{-f} & Force (really remove).\\ + \bt{-x} & Also remove \emph{ignored} files.\\ + \bt{-n} & Do a \emph{dry run}.\\ + \end{tabular} + \end{center} + \caption{Common options.} + \end{table} +\end{pframe} + \subsection{Working together on the same clone} \begin{pframe} Sometimes you need to work with other people on the same repository clone. @@ -331,8 +365,9 @@ Martijn Vermaat - Zuotian Tatum + Wibowo Arindrarto + Zuotian Tatum \end{center} \vfill diff --git a/skeleton/skeleton_handouts.tex b/skeleton/skeleton_handouts.tex index e8cb27da8e92dcb0e1c3e9432fb2c7eeb249f8a4..e402b00dbe9d4e0d3f53235fea54fe8aa0795232 100644 --- a/skeleton/skeleton_handouts.tex +++ b/skeleton/skeleton_handouts.tex @@ -71,6 +71,13 @@ With the ``\texttt{file}'' command you can now see that $ git pull $ git annex get bigfile.dat \end{lstlisting} + +\newpage + +Let the original repository know that you have a copy. +\begin{lstlisting} + $ git annex sync +\end{lstlisting} \bigskip You can now remove the big data file from the original repository.