README.md in rubydora-2.1.0 vs README.md in rubydora-2.2.0

- old
+ new

@@ -1,40 +1,60 @@ # rubydora -[<img src="https://travis-ci.org/projecthydra/rubydora.png?branch=master" -alt="Build Status" />](https://travis-ci.org/projecthydra/rubydora) [<img -src="https://badge.fury.io/rb/rubydora.png" alt="Gem Version" -/>](http://badge.fury.io/rb/rubydora) Rubydora is a low-level Fedora Commons REST API consumer, providing direct access to REST API methods, as well as a primitive ruby abstraction. +Code: +[![Gem Version](https://badge.fury.io/rb/rubydora.png)](http://badge.fury.io/rb/rubydora) +[![Build Status](https://circleci.com/gh/samvera/rubydora.svg?style=svg)](https://circleci.com/gh/samvera/rubydora) +[![Coverage Status](https://coveralls.io/repos/github/samvera/rubydora/badge.svg?branch=main)](https://coveralls.io/github/samvera/rubydora?branch=main) + +Docs: +[![Contribution Guidelines](http://img.shields.io/badge/CONTRIBUTING-Guidelines-blue.svg)](./CONTRIBUTING.md) +[![Apache 2.0 License](http://img.shields.io/badge/APACHE2-license-blue.svg)](./LICENSE.txt) + +Community Support: [![Samvera Community Slack](https://img.shields.io/badge/samvera-slack-blueviolet)](http://slack.samvera.org/) + +## Product Owner & Maintenance + +`rubydora` was a Core Component of the Samvera Community. Given a decline in available labor required for maintenance, this project no longer has a dedicated Product Owner. The documentation for what this means can be found [here](http://samvera.github.io/core_components.html#requirements-for-a-core-component). + +### Product Owner +**Vacant** + +_Until a Product Owner has been identified, we ask that you please direct all requests for support, bug reports, and general questions to the [`#dev` Channel on the Samvera Slack](https://samvera.slack.com/app_redirect?channel=dev)._ + +## Help + +The Samvera community is here to help. Please see our [support guide](./SUPPORT.md). + ## Installation ```bash gem install rubydora ``` ## Examples ``` > repo = Rubydora.connect :url => 'http://localhost:8983/fedora', :user => 'fedoraAdmin', :password => 'fedoraAdmin' -=> #<Rubydora::Repository:0x101859538 @config={:url=>"http://localhost:8983/fedora", :user=>"fedoraAdmin", :password=>"fedoraAdmin"}> +=> #<Rubydora::Repository:0x101859538 @config={:url=>"http://localhost:8983/fedora", :user=>"fedoraAdmin", :password=>"fedoraAdmin"}> > obj = repo.find('test:1') -=> #<Rubydora::DigitalObject:0x101977230 @pid="test:1", @repository=#<Rubydora::Repository:0x1019beef0 @config={:user=>"fedoraAdmin", :url=>"http://localhost:8983/fedora", :password=>"fedora"}>> +=> #<Rubydora::DigitalObject:0x101977230 @pid="test:1", @repository=#<Rubydora::Repository:0x1019beef0 @config={:user=>"fedoraAdmin", :url=>"http://localhost:8983/fedora", :password=>"fedora"}>> > obj.new? -=> true +=> true > obj = obj.save -=> #<Rubydora::DigitalObject:0x1017601b8 @pid="test:1", @repository=#<Rubydora::Repository:0x1018e3058 @config={:url=>"http://localhost:8983/fedora", :user=>"fedoraAdmin", :password=>"fedoraAdmin"}, @client=#<RestClient::Resource:0x101882910 @options={:user=>"fedoraAdmin", :password=>"fedoraAdmin"}, @block=nil, @url="http://localhost:8983/fedora">>> +=> #<Rubydora::DigitalObject:0x1017601b8 @pid="test:1", @repository=#<Rubydora::Repository:0x1018e3058 @config={:url=>"http://localhost:8983/fedora", :user=>"fedoraAdmin", :password=>"fedoraAdmin"}, @client=#<RestClient::Resource:0x101882910 @options={:user=>"fedoraAdmin", :password=>"fedoraAdmin"}, @block=nil, @url="http://localhost:8983/fedora">>> > obj.profile -=> {"objDissIndexViewURL"=>"http://localhost:8983/fedora/get/test:1/fedora-system:3/viewMethodIndex", "objLabel"=>"", "objModels"=>"info:fedora/fedora-system:FedoraObject-3.0", "objCreateDate"=>"2011-04-18T13:34:11.285Z", "objOwnerId"=>"fedoraAdmin", "objState"=>"A", "objItemIndexViewURL"=>"http://localhost:8983/fedora/get/test:1/fedora-system:3/viewItemIndex", "objLastModDate"=>"2011-04-18T13:47:30.110Z"} +=> {"objDissIndexViewURL"=>"http://localhost:8983/fedora/get/test:1/fedora-system:3/viewMethodIndex", "objLabel"=>"", "objModels"=>"info:fedora/fedora-system:FedoraObject-3.0", "objCreateDate"=>"2011-04-18T13:34:11.285Z", "objOwnerId"=>"fedoraAdmin", "objState"=>"A", "objItemIndexViewURL"=>"http://localhost:8983/fedora/get/test:1/fedora-system:3/viewItemIndex", "objLastModDate"=>"2011-04-18T13:47:30.110Z"} > obj.models -=> ["info:fedora/fedora-system:FedoraObject-3.0"] +=> ["info:fedora/fedora-system:FedoraObject-3.0"] > obj.models << 'info:fedora/test:cmodel' => ["info:fedora/fedora-system:FedoraObject-3.0", "info:fedora/test:cmodel"] > obj2 = repo.find('test:2') @@ -54,25 +74,49 @@ => "http://example.org/index.html" > ds.dsLabel = 'Example redirect datastream' => "Example redirect datastream" > ds.mimeType = 'text/html' => "text/html" -> ds.save -=> #<Rubydora::Datastream:0x10177a568 @dsid="File" ...> +> ds.save +=> #<Rubydora::Datastream:0x10177a568 @dsid="File" ...> > obj.datastreams => {"DC"=>#<Rubydora::Datastream:0x101860180 @dsid="DC" ..., "File"=>#<Rubydora::Datastream:0x10177a568 @dsid="File" ...>} > obj.datastreams["File"].delete => true > obj.datastreams["File"].new? => true ``` +## Running the Tests + +There is a Dockerfile included here to build a container that runs fcrepo3. It +will listen on port 8983, so no additional configuration is required. You can +run the continuous integration suite or the specs directly. An example of +starting the server and running just the specs is included here: + +``` +docker build -t samvera/fcrepo3:latest . +RUBYDORA_ID=$(docker run -d -p 8983:8983 samvera/fcrepo3:latest) +bundle exec rspec && docker kill $RUBYDORA_ID +``` + +There are also Rake tasks for building the image and running the suite against +a container: + +``` +bundle exec rake docker:build +bundle exec rake docker:spec +``` + ## Contributing to rubydora -* Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet +* If you're working on PR for this project, create a feature branch off of `main`. + + This repository follows the [Samvera Community Code of Conduct](https://samvera.atlassian.net/wiki/spaces/samvera/pages/405212316/Code+of+Conduct) and [language recommendations](https://github.com/samvera/maintenance/blob/main/templates/CONTRIBUTING.md#language). Please ***do not*** create a branch called `master` for this repository or as part of your pull request; the branch will either need to be removed or renamed before it can be considered for inclusion in the code base and history of this repository. +* Check out the latest main branch to make sure the feature hasn't been implemented or the bug hasn't been fixed yet * Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it * Fork the project * Start a feature/bugfix branch * Commit and push until you are happy with your contribution * Make sure to add tests for it. This is important so I don't break it in a future version unintentionally. @@ -82,5 +126,14 @@ ## Copyright Copyright (c) 2011 Chris Beer. See LICENSE.txt for further details. +## Acknowledgments + +This software has been developed by and is brought to you by the Samvera community. Learn more at the [Samvera website](http://samvera.org/). + +![Samvera Logo](https://wiki.duraspace.org/download/thumbnails/87459292/samvera-fall-font2-200w.png?version=1&modificationDate=1498550535816&api=v2) + +## Contributing + +Bug reports and pull requests are welcome on GitHub at https://github.com/samvera/rubydora/.