Skip to content
This repository was archived by the owner on Dec 12, 2025. It is now read-only.

Commit

Permalink
Merge pull request #17 from CLASS/revert-16-gcp-dev
Browse files Browse the repository at this point in the history
Revert "GCP: Remove from git workflow and replace with wget+unzip"
  • Loading branch information
amanda-tan authored Feb 6, 2022
2 parents 852d5e8 + 2e2aa08 commit 23d266b
Showing 1 changed file with 23 additions and 80 deletions.
103 changes: 23 additions & 80 deletions content/GCP/06_running_analysis.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -233,12 +233,12 @@
"source": [
"## Get Example Code\n",
"\n",
"We will now install `wget` and `unzip` and use it to download the example code into your home directory. "
"We will now install `git` and use it to download the example code into your home directory. For those of you who are unfamiliar with git, it is a way to collaboratively manage files and we will only be using it to download the example that we will be using. "
]
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 5,
"id": "05fadd30-4f35-4a93-b713-cc132131b948",
"metadata": {},
"outputs": [
Expand All @@ -249,101 +249,44 @@
"Reading package lists... Done\n",
"Building dependency tree \n",
"Reading state information... Done\n",
"Suggested packages:\n",
" zip\n",
"The following NEW packages will be installed:\n",
" unzip wget\n",
"0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.\n",
"Need to get 1074 kB of archives.\n",
"After this operation, 3915 kB of additional disk space will be used.\n",
"Get:1 http://deb.debian.org/debian buster/main amd64 wget amd64 1.20.1-1.1 [902 kB]\n",
"Get:2 http://deb.debian.org/debian buster/main amd64 unzip amd64 6.0-23+deb10u2 [172 kB]\n",
"Fetched 1074 kB in 0s (40.4 MB/s)\n",
"Selecting previously unselected package wget.\n",
"(Reading database ... 57683 files and directories currently installed.)\n",
"Preparing to unpack .../wget_1.20.1-1.1_amd64.deb ...\n",
"Unpacking wget (1.20.1-1.1) ...\n",
"Selecting previously unselected package unzip.\n",
"Preparing to unpack .../unzip_6.0-23+deb10u2_amd64.deb ...\n",
"Unpacking unzip (6.0-23+deb10u2) ...\n",
"Setting up wget (1.20.1-1.1) ...\n",
"Setting up unzip (6.0-23+deb10u2) ...\n",
"Processing triggers for mime-support (3.62) ...\n",
"Processing triggers for man-db (2.8.5-2) ...\n"
"git is already the newest version (1:2.20.1-2+deb10u3).\n",
"0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.\n"
]
}
],
"source": [
"sudo apt-get install --yes wget unzip"
"sudo apt-get install --yes git"
]
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 6,
"id": "96db6a66-3fbf-419a-b8c8-dbb27639e990",
"metadata": {},
"outputs": [],
"source": [
"cd ~"
]
},
{
"cell_type": "markdown",
"id": "bebfa80a-85c7-4040-82d8-ff495b51324d",
"metadata": {},
"source": [
"Download the zip file `-nv` to make the output less verbose."
]
},
{
"cell_type": "code",
"execution_count": 2,
"execution_count": 7,
"id": "36554c99-ba08-4733-8ef2-e68d42d0d2b7",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"2022-02-04 22:33:37 URL:https://github.internet2.edu/_codeload/CLASS/CLASS-Examples/zip/v1 [5482/5482] -> \"v1.zip\" [1]\n"
]
}
],
"source": [
"wget -nv https://github.internet2.edu/CLASS/CLASS-Examples/archive/v1.zip"
]
},
{
"cell_type": "code",
"execution_count": 3,
"id": "7418ed55-9f57-4e15-b9c7-8fe39e59ec29",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"Archive: v1.zip\n",
"b3d47595a1679f3416774de87f76d5a2b9fe65bf\n",
" creating: CLASS-Examples-1/\n",
" inflating: CLASS-Examples-1/.gitignore \n",
" creating: CLASS-Examples-1/bayeswave/\n",
" extracting: CLASS-Examples-1/bayeswave/.gitignore \n",
" inflating: CLASS-Examples-1/bayeswave/ReadMe.md \n",
" inflating: CLASS-Examples-1/bayeswave/bayeswave-job.yaml \n",
" creating: CLASS-Examples-1/landsat/\n",
" inflating: CLASS-Examples-1/landsat/ReadMe.md \n",
" inflating: CLASS-Examples-1/landsat/clean.sh \n",
" inflating: CLASS-Examples-1/landsat/combine.py \n",
" inflating: CLASS-Examples-1/landsat/download.sh \n",
" inflating: CLASS-Examples-1/landsat/get-index.sh \n",
" inflating: CLASS-Examples-1/landsat/search.json \n",
" inflating: CLASS-Examples-1/landsat/search.py \n"
"Cloning into 'CLASS-Examples'...\n",
"remote: Enumerating objects: 66, done.\u001b[K\n",
"remote: Total 66 (delta 0), reused 0 (delta 0), pack-reused 66\u001b[K\n",
"Unpacking objects: 100% (66/66), done.\n"
]
}
],
"source": [
"unzip v1.zip"
"git clone https://github.internet2.edu/CLASS/CLASS-Examples.git"
]
},
{
Expand All @@ -356,12 +299,12 @@
},
{
"cell_type": "code",
"execution_count": 4,
"execution_count": 8,
"id": "90c1cda7-60d4-44bb-84f8-e776a77a94ab",
"metadata": {},
"outputs": [],
"source": [
"cd ~/CLASS-Examples-1/landsat/"
"cd ~/CLASS-Examples/landsat/"
]
},
{
Expand All @@ -371,13 +314,13 @@
"source": [
"Your prompt should now change showing the current directory as follows.\n",
"```\n",
"learner@essentials:~/CLASS-Examples-1/landsat$\n",
"learner@essentials:~/CLASS-Examples/landsat$\n",
"```"
]
},
{
"cell_type": "code",
"execution_count": 6,
"execution_count": 9,
"id": "55b628d5-6e5c-45a5-9cd3-c129db9cdcd2",
"metadata": {},
"outputs": [
Expand All @@ -386,13 +329,13 @@
"output_type": "stream",
"text": [
"total 28\n",
"-rw-r--r-- 1 learner learner 960 Dec 13 20:53 ReadMe.md\n",
"-rw-r--r-- 1 learner learner 72 Dec 13 20:53 clean.sh\n",
"-rw-r--r-- 1 learner learner 613 Dec 13 20:53 combine.py\n",
"-rw-r--r-- 1 learner learner 280 Dec 13 20:53 download.sh\n",
"-rw-r--r-- 1 learner learner 314 Dec 13 20:53 get-index.sh\n",
"-rw-r--r-- 1 learner learner 76 Dec 13 20:53 search.json\n",
"-rw-r--r-- 1 learner learner 783 Dec 13 20:53 search.py\n"
"-rw-r--r-- 1 learner learner 960 Jan 21 21:32 ReadMe.md\n",
"-rw-r--r-- 1 learner learner 72 Jan 21 21:32 clean.sh\n",
"-rw-r--r-- 1 learner learner 613 Jan 21 21:32 combine.py\n",
"-rw-r--r-- 1 learner learner 280 Jan 21 21:32 download.sh\n",
"-rw-r--r-- 1 learner learner 314 Jan 21 21:32 get-index.sh\n",
"-rw-r--r-- 1 learner learner 76 Jan 21 21:32 search.json\n",
"-rw-r--r-- 1 learner learner 783 Jan 21 21:32 search.py\n"
]
}
],
Expand Down

0 comments on commit 23d266b

Please sign in to comment.