Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
Co-Authored-By: Daniel Spiewak <djspiewak@gmail.com>
  • Loading branch information
xerial and djspiewak committed Apr 20, 2020
1 parent 9d186c4 commit 56f622b
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -136,11 +136,10 @@ The following setting keys are defined:
- `githubSuppressPublicationWarning : Boolean` (*defaults to `false`*) If you're just using this plugin as a means to *resolve* artifacts, not to publish them, the publication warning may serve as an annoyance more than anything else. Setting this to `true` will suppress the normal warning text when you fail to define `githubOwner` or `githubRepository`.
- `githubPublishTo : Option[Resolver]` The default `publishTo` target for GitHub Packages. This setting is useful for switching `publishTo` target to [sbt-sonatype](https://github.com/xerial/sbt-sonatype) or GitHub Packages:

```scala
// Switch publishTo target for using Sonatype if RELEASE_SONATYPE env is true,
// otherwise publish to GitHub Packages:
val RELEASE_TO_SONATYPE = sys.env.getOrElse("RELEASE_SONATYPE", "false").toBoolean
publishTo := if(RELEASE_SONATYPE) sonatypePublishTo.value else githubPublishTo.value
```
```scala
// Switch publishTo target for using Sonatype if RELEASE_SONATYPE env is true,
// otherwise publish to GitHub Packages:
val RELEASE_TO_SONATYPE = sys.env.getOrElse("RELEASE_SONATYPE", "false").toBoolean
publishTo := if(RELEASE_SONATYPE) sonatypePublishTo.value else githubPublishTo.value

`homepage` and `scmInfo` will be automatically set for you if `githubOwner` and `githubRepository` are themselves set.

0 comments on commit 56f622b

Please sign in to comment.