Skip to content
David Cliff edited this page Oct 2, 2013 · 28 revisions

Welcome to the drs-sufia-app wiki!

Creating the first parent collection on an empty repository

Loading development environment (Rails 3.2.13)
irb(main):001:0>  a = NuCollection.new(pid: 'neu:1', identifier: 'neu:1', title: 'Root Collection')
=> #<NuCollection pid:"neu:1", nu_title:["Root Collection"], nu_description:[""], nu_identifier:["neu:1"], depositor:nil>
irb(main):002:0>  a.rightsMetadata.permissions({group: 'public'}, 'read')
=> "read"
irb(main):003:0> a.rightsMetadata.permissions({person: "dev_email_account_here"}, 'edit')
=> "edit"
irb(main):004:0> a.save!
=> true

Pushing to Repository Dev server

repositorydev.neu.edu has now been setup so that it contains a remote git location, just like how we use GitHub. This is beneficial for two reasons.

  1. No more worrying when GitHub goes down.
  2. It has been setup so that when you push to the server (to which I will refer to colloquially as repdev) it then updates repositorydev.neu.edu. Currently, all it does is cd into the working copy and do a git pull. Any changes that require a restart of the rails server will need to be done manually.

To utilize this, some changes need to made to your local git config.

To add repdev by itself:

git remote add repdev ssh://[email protected]/home/drs/drs.git

To make a new remote called 'all' so as to only run through tests once (saving time) and to keep GitHub and RepDev in sync, add this to .git/config

[remote "all"]
    url = [email protected]:nu-lts/drs.git
    url = ssh://[email protected]/home/drs/drs.git

An example push after these changes

git push all develop

N.B. You may notice that the url for the repdev git connection is done with ssh. This means you will be prompted to put in the drs users password. There are two ways to make this less painful.

Clone this wiki locally