Skip to content
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

Create a new gist #90

Open
willhains opened this issue Jan 7, 2022 · 2 comments
Open

Create a new gist #90

willhains opened this issue Jan 7, 2022 · 2 comments

Comments

@willhains
Copy link

Would it be possible to create a new gist, rather than update an existing one?

Something like this:

- uses: actions/checkout@v2
- name: Deploy
  id: create-gist
  uses: exuanbo/actions-deploy-gist@v1
  with:
    token: ${{ secrets.TOKEN }}
    # Omit gist_id to create a new gist
    gist_description: "foo bar"
    gist_file_name: foo.bar
    file_path: ./dist/foo.bar
- name: Generate URL
  # Use output `gist_id` to get the created gist
  run: echo "https://some.endpoint.io?gistId=${{steps.create-gist.outputs.gist_id}}.json"
@willhains
Copy link
Author

willhains commented Jan 7, 2022

The Gist API seems to support creating new Gists, but I couldn't find any Actions in the Marketplace for this.

@exuanbo
Copy link
Owner

exuanbo commented Jan 8, 2022

Seems a good idea. For now I think the only way is using a shell script to create new gists.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants