-
Notifications
You must be signed in to change notification settings - Fork 237
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
circleci learned orb source
#35
Conversation
`circleci orb source circleci/gradle` will print the source of the gradle orb.
Codecov Report
@@ Coverage Diff @@
## master #35 +/- ##
==========================================
- Coverage 38.76% 38.68% -0.08%
==========================================
Files 12 12
Lines 841 853 +12
==========================================
+ Hits 326 330 +4
- Misses 491 499 +8
Partials 24 24
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$ go run main.go orb source circleci/gradle
executor:
gradle:
description: The docker container to use when running Gradle builds
docker:
- image: circleci/openjdk:8-jdk-node
environment:
# Disable fancy terminal updates
TERM: dumb
commands:
with_cache:
description: |
Run a set of steps with gradle dependencies cached.
This command will first restore a cache of gradle dependencies, if one was
saved by a previous build. The provided `steps` will then be executed, and
if successful, then a fresh cache will be saved, if required.
The contents of the `~/.gradle` directory is cached, which will substantially
improve build times for projects with many dependencies.
The cache-key is generated from any files named `build.gradle` that are
present in the `working_directory`.
parameters:
steps:
type: steps
steps:
- run:
name: Generate Cache Checksum
command: find . -name 'build.gradle' -exec cat {} + | shasum | awk '{print $1}' > /tmp/gradle_cache_seed
- restore_cache:
key: gradle-{{ checksum "/tmp/gradle_cache_seed" }}
- << parameters.steps >>
- save_cache:
paths:
- ~/.gradle
key: gradle-{{ checksum "/tmp/gradle_cache_seed" }}
jobs:
test:
description: |
Checkout, build and test a gradle project.
executor: gradle
parameters:
test_command:
type: string
default: test
steps:
- checkout
- with_cache:
steps:
- run:
name: Run Tests
command: ./gradlew << parameters.test_command >>
$ go run main.go orb source circleci/gradl
Error: Failed to get source for 'circleci/gradl': graphql: Non-nullable field was null.
exit status 255
This is looking good!
I think we should wrap the graphql error in the CLI. That response makes a user error look like a server error.
This is a server error as far as I can tell. |
I'll make a follow up ticket for this. LGTM |
circleci orb source circleci/gradle
will print the source of thegradle orb.