Skip to content

Commit f7add75

Browse files
authored
Merge pull request #42 from CU-ESIIL/codex/update-mkdocs-site-for-gocmd-instructions
Update gocmd instructions and transfer examples
2 parents 1a98b22 + 48479d9 commit f7add75

File tree

3 files changed

+56
-16
lines changed

3 files changed

+56
-16
lines changed

docs/instructions/day2.md

Lines changed: 31 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,24 +23,47 @@ permalink: /instructions/day2/
2323
GOCMD_VER=$(curl -L -s https://raw.githubusercontent.com/cyverse/gocommands/main/VERSION.txt); \
2424
curl -L -s https://github.com/cyverse/gocommands/releases/download/${GOCMD_VER}/gocmd-${GOCMD_VER}-linux-amd64.tar.gz | tar zxvf -
2525

26-
# Initialize and authenticate
26+
# Configure iRODS (accept defaults for Host/Port/Zone; use your CyVerse username)
2727
./gocmd init
28-
./gocmd auth login # follow prompts for CyVerse credentials
2928

30-
# Optionally confirm access to your home directory
29+
# Quick sanity check: can you list your home?
3130
./gocmd ls i:/iplant/home/YOUR_USER
3231
```
3332

34-
> Remote Data Store paths must include the `i:` prefix (for example, `i:/iplant/home/...`). Local paths should omit it.
33+
> `i:` indicates an iRODS remote path. Omit `i:` for local filesystem paths.
3534
3635
**Example transfers:**
3736

3837
```bash
39-
# Upload a local file to the Data Store
40-
./gocmd put ./outputs/figure1.png i:/iplant/home/YOUR_USER/sprint/figure1.png
38+
# Single file download (shared path → local ./data/)
39+
./gocmd get --progress -K --icat \
40+
i:/iplant/home/shared/earthlab/nfs_career/outputs/SUMMER_2024/Buffalo_creek-BC1-06_20_24/Buffalo_creek-BC1-06_20_24_1_all_layers.tif \
41+
./data/
42+
43+
# Folder download (entire collection)
44+
./gocmd get --progress -K --icat -r \
45+
i:/iplant/home/shared/earthlab/nfs_career/outputs/SUMMER_2024/Buffalo_creek-BC3-06_20_24 \
46+
./data/
47+
48+
# Upload a results folder to your home
49+
./gocmd put --progress -K --icat -r \
50+
./outputs/run_01 \
51+
i:/iplant/home/YOUR_USER/projects/myproj/outputs/run_01
52+
53+
# Optional sync-like upload to skip unchanged files
54+
./gocmd put --progress -K --icat --diff -r \
55+
./outputs/run_01 \
56+
i:/iplant/home/YOUR_USER/projects/myproj/outputs/run_01
57+
```
58+
59+
> **Troubleshooting:**
60+
```bash
61+
# If a path "is not found", list upward, then drill down to confirm exact names
62+
./gocmd ls i:/iplant/home/shared/earthlab/nfs_career/outputs/SUMMER_2024
63+
./gocmd ls i:/iplant/home/shared/earthlab/nfs_career/outputs/SUMMER_2024/Buffalo*
4164

42-
# Download from the Data Store to your working dir
43-
./gocmd get i:/iplant/home/YOUR_USER/sprint/input.csv ./data/input.csv
65+
# Inspect type and permissions if a collection exists but transfers fail
66+
./gocmd stat i:/iplant/home/shared/earthlab/nfs_career/outputs/SUMMER_2024/<EXACT_NAME>
4467
```
4568

4669
> Keep large data out of GitHub. Store externally, link from the **Data** page.

docs/instructions/save-to-persistent-storage.md

Lines changed: 22 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,17 @@ permalink: /instructions/save/
66

77
# Save to Persistent Storage with GoCommands
88

9-
### 0) One-time setup (install + login)
9+
### 0) One-time setup (install + init)
1010
```bash
1111
# Install GoCommands (Linux x86_64)
1212
GOCMD_VER=$(curl -L -s https://raw.githubusercontent.com/cyverse/gocommands/main/VERSION.txt); \
1313
curl -L -s https://github.com/cyverse/gocommands/releases/download/${GOCMD_VER}/gocmd-${GOCMD_VER}-linux-amd64.tar.gz | tar zxvf -
1414

15-
# Configure iRODS (accept defaults for Host/Port/Zone; use your CyVerse creds)
15+
# Configure iRODS (accept defaults for Host/Port/Zone; use your CyVerse username)
1616
./gocmd init
17-
./gocmd auth login # follow prompts to authenticate with CyVerse
17+
18+
# Quick sanity check: can you list your home?
19+
./gocmd ls i:/iplant/home/YOUR_USER
1820
```
1921

2022
**Community folder root (read/write for teams):**
@@ -32,7 +34,7 @@ COMMUNITY="i:/iplant/home/shared/esiil/Innovation_summit/${GROUP_NAME}"
3234
PERSONAL="i:/iplant/home/${USERNAME}"
3335
```
3436

35-
> **Note:** GoCommands uses `i:` to denote paths on the CyVerse Data Store. Include this prefix for any remote path (for example, `i:/iplant/home/...`). Local filesystem paths should not have the `i:` prefix.
37+
> **Note:** `i:` indicates an iRODS remote path. Omit `i:` for local filesystem paths.
3638
3739
---
3840

@@ -42,7 +44,10 @@ PERSONAL="i:/iplant/home/${USERNAME}"
4244
LOCAL_SRC="outputs/run-YYYYMMDD"
4345
REMOTE_DST="${COMMUNITY}/outputs/"
4446

45-
./gocmd put --icat --retry 3 -d -k -r "${LOCAL_SRC}" "${REMOTE_DST}"
47+
./gocmd put --progress -K --icat -r "${LOCAL_SRC}" "${REMOTE_DST}"
48+
49+
# Optional sync-like upload to skip unchanged files
50+
./gocmd put --progress -K --icat --diff -r "${LOCAL_SRC}" "${REMOTE_DST}"
4651
```
4752
- `put` uploads from local → CyVerse Data Store
4853
- `-r` is recursive; `--diff` (optional) only sends changed files
@@ -52,6 +57,16 @@ Verify upload:
5257
./gocmd ls "${REMOTE_DST}"
5358
```
5459

60+
> **Troubleshooting:**
61+
```bash
62+
# If a path "is not found", list upward, then drill down to confirm exact names
63+
./gocmd ls i:/iplant/home/shared/esiil/Innovation_summit
64+
./gocmd ls i:/iplant/home/shared/esiil/Innovation_summit/${GROUP_NAME}
65+
66+
# Inspect type and permissions if a collection exists but transfers fail
67+
./gocmd stat i:/iplant/home/shared/esiil/Innovation_summit/${GROUP_NAME}/<EXACT_NAME>
68+
```
69+
5570
---
5671

5772
## B) **Pull** data **from the community folder**
@@ -61,7 +76,7 @@ mkdir -p ./data
6176
REMOTE_SRC="${COMMUNITY}/shared_data/"
6277
LOCAL_DST="./data/"
6378

64-
./gocmd get --icat --retry 3 -d -k -r "${REMOTE_SRC}" "${LOCAL_DST}"
79+
./gocmd get --progress -K --icat -r "${REMOTE_SRC}" "${LOCAL_DST}"
6580
```
6681
- `get` downloads from CyVerse → local machine
6782
- Use for pulling common datasets your team prepared
@@ -74,7 +89,7 @@ LOCAL_DST="./data/"
7489
REMOTE_SRC="i:/iplant/home/shared/esiil/Innovation_summit/${GROUP_NAME}/deliverables/"
7590
REMOTE_PERSONAL_DST="i:/iplant/home/${USERNAME}/projects/innovation_summit_2025/deliverables/"
7691

77-
./gocmd cp --icat --retry 3 -d -k -r "${REMOTE_SRC}" "${REMOTE_PERSONAL_DST}"
92+
./gocmd cp --progress -K --icat -r "${REMOTE_SRC}" "${REMOTE_PERSONAL_DST}"
7893

7994
# Verify contents
8095
./gocmd ls "${REMOTE_PERSONAL_DST}"

docs/project_template.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,9 @@ Project one-liner: _(write it here)_
107107
GOCMD_VER=$(curl -L -s https://raw.githubusercontent.com/cyverse/gocommands/main/VERSION.txt); \
108108
curl -L -s https://github.com/cyverse/gocommands/releases/download/${GOCMD_VER}/gocmd-${GOCMD_VER}-linux-amd64.tar.gz | tar zxvf -
109109
./gocmd init
110-
./gocmd auth login # follow prompts to authenticate
110+
111+
# Quick sanity check: can you list your home?
112+
./gocmd ls i:/iplant/home/YOUR_USER
111113
```
112114

113115
> *(macOS uses a different tarball)*

0 commit comments

Comments
 (0)