@artsy/update-repo
TypeScript icon, indicating that this package has built-in type declarations

0.6.0 • Public • Published

@artsy/update-repo

Update github repos with a pull request.

Installation

yarn add @artsy/update-repo

Usage

Aside from node, you need two things in your execution environment to make this work:

import { updateRepo } from "@artsy/update-repo"

await updateRepo({
  repo: { owner: "artsy", repo: "metaphysics" },
  branch: "update-npm-dependency",
  targetBranch: "main",
  title: "Update the version for my-npm-package",
  body: "bleep bloop :robot:",
  commitMessage: "update version",
  assignees: ["ds300"],
  labels: ["automated"],
  update: (dir) => {
    // This update function gets executed in a freshly-checked-out version
    // of the repo you specified. If you make any changes here they will
    // be committed and added to a PR.
    execSync(`yarn add my-npm-package@${newVersion}`, { cwd: dir })
  },
})

About Artsy

This project is the work of engineers at Artsy, the world's leading and largest online art marketplace and platform for discovering art. One of our core Engineering Principles is being Open Source by Default which means we strive to share as many details of our work as possible.

You can learn more about this work from our blog and by following @ArtsyOpenSource or explore our public data by checking out our API. If you're interested in a career at Artsy, read through our job postings!

Readme

Keywords

none

Package Sidebar

Install

npm i @artsy/update-repo

Weekly Downloads

1,030

Version

0.6.0

License

MIT

Unpacked Size

31.2 kB

Total Files

8

Last publish

Collaborators

  • joeyaghion
  • artsy-engineering
  • damassi
  • anandaroop
  • mzikherman
  • dblandin