{"id":18389306,"url":"https://github.com/rightpoint/circleci_artifact","last_synced_at":"2025-04-12T05:21:34.043Z","repository":{"id":62555687,"uuid":"129815075","full_name":"Rightpoint/circleci_artifact","owner":"Rightpoint","description":"Easily fetch CircleCI artifact URLs","archived":false,"fork":false,"pushed_at":"2018-04-19T20:59:33.000Z","size":21,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":9,"default_branch":"master","last_synced_at":"2024-09-17T11:29:15.780Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Rightpoint.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-04-16T22:48:08.000Z","updated_at":"2018-04-19T20:59:34.000Z","dependencies_parsed_at":"2022-11-03T05:45:20.576Z","dependency_job_id":null,"html_url":"https://github.com/Rightpoint/circleci_artifact","commit_stats":null,"previous_names":["raizlabs/circleci_artifact"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Rightpoint%2Fcircleci_artifact","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Rightpoint%2Fcircleci_artifact/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Rightpoint%2Fcircleci_artifact/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Rightpoint%2Fcircleci_artifact/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Rightpoint","download_url":"https://codeload.github.com/Rightpoint/circleci_artifact/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248520246,"owners_count":21117905,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T01:42:29.061Z","updated_at":"2025-04-12T05:21:34.012Z","avatar_url":"https://github.com/Rightpoint.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# circleci_artifact\n\n[![CircleCI](https://img.shields.io/circleci/project/github/Raizlabs/circleci_artifact/master.svg)](https://circleci.com/gh/Raizlabs/circleci_artifact)\n\nThis library is designed to make fetching the URLs for [CircleCI build artifacts](https://circleci.com/docs/2.0/artifacts/#downloading-all-artifacts-for-a-build-on-circleci) quick and easy. Unfortunately CircleCI makes it difficult to get the URLs for your build artifacts without hitting their API, so it's not straightforward to include links to your artifacts as part of the CI process.\n\nThis gem was built to be used in combination with tools like [Fastlane](https://github.com/fastlane/fastlane) and [Danger](https://github.com/danger/danger). The functionality is very limited at this point, and just makes it easier to grab single artifacts whose URL match a substring.\n\n## Getting Started\n\n* Create a new CircleCI account for your CI bot user.\n* Create a CircleCI API token in the application by going to [User Settings \u003e Personal API Tokens](https://circleci.com/account/api).\n* Create a new token called `CIRCLE_API_TOKEN`. \n* Add `CIRCLE_API_TOKEN` to the CircleCI build environment for the target repo.\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'circleci_artifact'\n```\n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install circleci_artifact\n\n## Usage\n\n\n```ruby\nrequire 'circleci_artifact'\n\n# Set this yourself using the steps in \"Getting Started\"\ntoken = ENV['CIRCLE_API_TOKEN']\n\n# These are already in the Circle environment\n# https://circleci.com/docs/2.0/env-vars/#build-specific-environment-variables\nusername = ENV['CIRCLE_PROJECT_USERNAME']\nreponame = ENV['CIRCLE_PROJECT_REPONAME']\nbuild = ENV['CIRCLE_BUILD_NUM']\n\nfetcher = CircleciArtifact::Fetcher.new(token: token, username: username, reponame: reponame, build: build)\n\nxcov = CircleciArtifact::Query.new(url_substring: 'xcov/index.html')\nslather = CircleciArtifact::Query.new(url_substring: 'slather/index.html')\nscreenshots = CircleciArtifact::Query.new(url_substring: 'screenshots/index.html')\nqueries = [xcov, slather, screenshots]\nresults = fetcher.fetch_queries(queries)\n\nxcov_url = results.url_for_query(xcov)\nslather_url = results.url_for_query(slather)\nscreenshots_url = results.url_for_query(screenshots)\n\nputs \"xcov_url #{xcov_url}\"\nputs \"slather_url #{slather_url}\"\nputs \"screenshots_url #{screenshots_url}\"\n```\n\n## Development\n\nAfter checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.\n\nTo install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/Raizlabs/circleci_artifact. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.\n\n## License\n\nThe gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).\n\n## Code of Conduct\n\nEveryone interacting in the CircleciArtifact project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/Raizlabs/circleci_artifact/blob/master/CODE_OF_CONDUCT.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frightpoint%2Fcircleci_artifact","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frightpoint%2Fcircleci_artifact","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frightpoint%2Fcircleci_artifact/lists"}