21023: Just use the default retry delay profile in keepproxy.
[arvados.git] / doc / user / tutorials / git-arvados-guide.html.textile.liquid
index a46a1d9318a5a06e28d0be15e60ced23b076415d..a4ac2a5795c5072c5f06de7da0efaf6f96a6cbd4 100644 (file)
@@ -3,21 +3,19 @@ layout: default
 navsection: userguide
 title: Working with an Arvados git repository
 ...
+{% comment %}
+Copyright (C) The Arvados Authors. All rights reserved.
 
-This tutorial describes how to work with a new Arvados git repository. Working with an Arvados git repository is analogous to working with other public git repositories. It will show you how to upload custom scripts to a remote Arvados repository, so you can use it in Arvados pipelines.
+SPDX-License-Identifier: CC-BY-SA-3.0
+{% endcomment %}
+
+This tutorial describes how to work with an Arvados-managed git repository. Working with an Arvados git repository is very similar to working with other public git repositories.
 
 {% include 'tutorial_expectations' %}
 
 {% include 'tutorial_git_repo_expectations' %}
 
-{% include 'notebox_begin' %}
-For more information about using Git, try
-<notextile>
-<pre><code>$ <span class="userinput">man gittutorial</span></code></pre>
-</notextile> or *"search Google for Git tutorials":http://google.com/#q=git+tutorial*.
-{% include 'notebox_end' %}
-
-h2. Cloning an Arvados repository
+h2. Cloning a git repository
 
 Before you start using Git, you should do some basic configuration (you only need to do this the first time):
 
@@ -26,7 +24,7 @@ Before you start using Git, you should do some basic configuration (you only nee
 ~$ <span class="userinput">git config --global user.email $USER@example.com</span></code></pre>
 </notextile>
 
-On the Arvados Workbench, click on the dropdown menu icon <span class="fa fa-lg fa-user"></span> <span class="caret"></span> in the upper right corner of the top navigation menu to access the user settings menu, and click on the menu item *Repositories*. In the *Repositories* page, you should see the @$USER/tutorial@ repository listed in the *name* column.  Next to *name* is the column *URL*. Copy the *URL* value associated with your repository.  This should look like <notextile><code>https://git.{{ site.arvados_api_host }}/$USER/tutorial.git</code></notextile>. Alternatively, you can use <notextile><code>git@git.{{ site.arvados_api_host }}:$USER/tutorial.git</code></notextile>
+On the Arvados Workbench, click on the dropdown menu icon <i class="fa fa-lg fa-user"></i> in the upper right corner of the top navigation menu to access the Account Management menu, and click on the menu item *Repositories*. In the *Repositories* page, you should see the @$USER/tutorial@ repository listed in the *name* column.  Next to *name* is the column *URL*. Copy the *URL* value associated with your repository.  This should look like <notextile><code>https://git.{{ site.arvados_api_host }}/$USER/tutorial.git</code></notextile>. Alternatively, you can use <notextile><code>git@git.{{ site.arvados_api_host }}:$USER/tutorial.git</code></notextile>
 
 Next, on the Arvados virtual machine, clone your Git repository:
 
@@ -54,36 +52,36 @@ Create a git branch named *tutorial_branch* in the *tutorial* Arvados git reposi
 
 <notextile>
 <pre><code>~$ <span class="userinput">cd tutorial</span>
-~$ <span class="userinput">git checkout -b tutorial_branch</span>
+~/tutorial$ <span class="userinput">git checkout -b tutorial_branch</span>
 </code></pre>
 </notextile>
 
-h2. Adding files or scripts to an Arvados repository
+h2. Adding scripts to an Arvados repository
 
-First, create a file named *tutorial.txt* in the local repository. Although this tutorial shows how to add a text file to Arvados, the same steps can be used to add any of your custom bash, R, or python scripts to an Arvados repository.
+A git repository is a good place to store the CWL workflows that you run on Arvados.
 
-<notextile>
-<pre><code>~$ <span class="userinput">echo 'hello world' > tutorial.txt</span>
-</code></pre>
-</notextile>
+First, create a simple CWL CommandLineTool:
 
-Next, add the new file to the git index.
+notextile. <pre>~/tutorials$ <code class="userinput">nano hello.cwl</code></pre>
 
-<notextile>
-<pre><code>~$ <span class="userinput">git add tutorial.txt</span>
-</code></pre>
-</notextile>
+<notextile> {% code tutorial_hello_cwl as yaml %} </notextile>
 
-Next, commit all the changes to the local repository, along with a commit message that describes what this script does.
+Next, add the file to the git repository.  This tells @git@ that the file should be included on the next commit.
+
+notextile. <pre><code>~/tutorial$ <span class="userinput">git add hello.cwl</span></code></pre>
+
+Next, commit your changes.  All staged changes are recorded into the local git repository:
 
 <notextile>
-<pre><code>~$ <span class="userinput">git commit -a -m "Added tutorial.txt"</span>
+<pre><code>~/tutorial$ <span class="userinput">git commit -m "my first script"</span>
 </code></pre>
 </notextile>
 
-Finally, push the changes in the local repository to the remote repository.
+Finally, upload your changes to the remote repository:
 
 <notextile>
-<pre><code>~$ <span class="userinput">git push origin tutorial_branch</span>
+<pre><code>~/tutorial/crunch_scripts$ <span class="userinput">git push origin tutorial_branch</span>
 </code></pre>
 </notextile>
+
+The same steps can be used to add any of your custom bash, R, or python scripts to an Arvados repository.