-
Notifications
You must be signed in to change notification settings - Fork 9
Setup
Instructions for installing software needed to use versioning, files and servers associated with OHI.
See also the ohiprep README for an overview of files managed as:
-
text
files versioned with GitHub, and -
binary
other files backed up and accessed on the file server neptune.nceas.ucsb.edu.
Per the git documentation: "This is important because every Git commit uses this information, and it’s immutably baked into the commits you pass around." Launch Terminal in Mac or go to command line in Windows (Start > Run > cmd) and substitute John Doe with your info:
git config --global user.name jdoe
git config --global user.email johndoe@example.com
git config --list
You can check settings with the following:
git config --list
It is also possible to set permissions for a specific repo instead of 'globally'.
First, change to your home directory, then make a directory to store github repositories, aka repos:
cd ~
mkdir github
cd github
Clone a repo here; for example ohi-israel:
git clone https://github.com/OHI-Science/ohi-israel.git
cd ohi-israel
Now set user info for only this repo:
git config user.name "John Doe"
git config user.email "jdoe@example.com"
Windows only: allow saving of passwords for repo (Mac does this automatically):
git config credential.helper wincred
Now let's try a minimal test to make a local commit and then push changes up to the repo.
Check status of git:
git status
Touch a file from within the repo and check the status of git:
touch test.md
git status
Add the file to register a change in the file system and check status of git:
git add test.md
git status
Commit this change locally and check status of git:
git commit -m "testing"
git status
The response should be: "Your branch is ahead of 'origin/master' by 1 commit".
Now push back up to the repo on github, ie 'origin/master'
git push
You should get prompted for username and password first time, stored thereafter.
## GitHub ### Sign up for GitHubSign up for GitHub at http://github.com.
### Install GitHubDownload GitHub and install specific to your operating system.
### Fork a Repository After signing in, visit a GitHub repository, such as [ohicore](https://github.com/OHI-Science/ohicore) or [ohiprep](https://github.com/OHI-Science/ohiprep) and [fork](https://help.github.com/articles/fork-a-repo) your own copy.Go to menu File > New Project... > Version Control > Git and enter URL, directory and containing folder. (In example below be sure to substitute 'OHI-Science' with your GitHub username and 'ohigit' with the forked github repository.)
Once you're done, you should then see an extra Git pane in RStudio like:
You can then Commit changes to your local repository. Don't forget to also Push these commits to the remote repository (ie GitHub).
If upon executing a Push, you see an error like this (particularly on Mac), then you need to setup your Git identity:
error: unable to read askpass response from 'rpostback-askpass'
fatal: could not read Username for 'https://github.com': Device not configured
Another great, fast option is to use RStudio directly on Neptune. You just need to login here:
http://neptune.nceas.ucsb.edu/rstudio
It's as fully featured as the desktop version, and your session persists even when disconnected. You can clone a Github repository like ohiprep to your home folder (see above), and use the Upload function to transfer files whether into ohiprep (code / csvs) or /var/data/ohi/git-annex (larger / binary).
# UCSB Specific Access ## Neptune Linux File ServerTo connect to the binary (non-text) non-versioned (but backed up) files related to ohiprep, you will need access to the file server neptune.nceas.ucsb.edu
. Presuming you have been granted an account by BB on neptune, you can mount the file shares locally at NCEAS or with a virtual private network (VPN) connection offsite.
On Mac, Finder application, Go menu, Connect to Server...:
smb://neptune.nceas.ucsb.edu/data
smb://neptune.nceas.ucsb.edu/local
On Windows, map a network drive to:
\\neptune.nceas.ucsb.edu\data
\\neptune.nceas.ucsb.edu\local
Note: The above file shares are read-only. To use read and write shares, suffix with _edit
, eg \\neptune.nceas.ucsb.edu\data_edit
.
Mount shares on neptune.nceas.ucsb.edu
from any online connection outside NCEAS and get access to UCSB subscribed journals online using the UCSB virtual private network (VPN), which requires:
Note from Melanie: On Windows 8, due to increased security, you need to install the OpenVPN GUI client and then configure it to run as administrator prior to running that "configuration" file. Then restart everything.
## RDP to Vulcan Windows Server for ArcGIS, etcYou can use Vulcan to run remote Windows processes, particularly for ArcGIS and RStudio, or for just quickly browsing Neptune's files (since the servers are connected with high bandwidth). You will need to have been granted an account by BB and use the latest Remote Desktop Client software.
- Mac: Microsoft Remote Desktop app for Mac
- Windows: the Remote Desktop Client comes with all Microsoft operating systems.
Here's an example connection in the Mac RDP client: