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

100% automated release process #777

Closed
7 of 15 tasks
kamranayub opened this issue Apr 8, 2017 · 5 comments
Closed
7 of 15 tasks

100% automated release process #777

kamranayub opened this issue Apr 8, 2017 · 5 comments
Assignees
Labels
core team This issue should be done by an Excalibur core member stale This issue or PR has not had any activity recently tools

Comments

@kamranayub
Copy link
Member

kamranayub commented Apr 8, 2017

Context

We are very close to automating the release process for Excalibur.

Proposal

Goal: To cut a new release, push new GitHub release tag.

  • Excalibur repo should pull GH releases for latest stable (env var?)
  • Excalibur repo should build API docs
  • Docs should build at latest release tag AND edge
  • Docs should query GH for latest release information for homepage (env var?) on every build
    • BONUS: At build time, calculate file size and gzip size for minified release for homepage
  • Excalibur repo should inject GH releases into documentation TOC somehow (env var?)
  • On release tag, should trigger excalibur site build
  • On release tag, automation should publish a corresponding GH release in excalibur-dist repo. It should use the tagged version number.
  • On excalibur-dist release tag, CI should publish Nuget package
  • On excalibur-dist release tag, CI should publish npm package
  • On excalibur-dist release (alpha or release) dependent plugins/repos should automatically be updated
    • Excalibur Tiled
    • Excalibur Electron
    • Documentation
    • Samples

Notes

  • Assumes manual work has been done (pre-validation, merging PRs, etc.)
eonarheim pushed a commit that referenced this issue Apr 11, 2017
Related #777

## Changes:

- Trigger site build on tagged commit or master branch
eonarheim pushed a commit that referenced this issue Apr 11, 2017
Related #777

## Changes:

- Dynamically fetch latest release at build time
@kamranayub
Copy link
Member Author

For Typedoc, it would be best to generate docs inside this repository but have the site repo publish the docs. That way, we always ensure the docs can build in CI and use the right version, but the site repo can slurp them up and publish them to the appropriate location (tag or edge)

eonarheim pushed a commit that referenced this issue Apr 15, 2017
Related #777

## Changes:

- Update grunt-ts for TS 2.2.2
- Add rimraf package
- Update specs for new Node typings
- Add `apidocs` Grunt task that builds Typedoc docs

See a2a78b6 for the actual real changes.

This is in preparation for allowing the excaliburjs/excaliburjs.github.io repository to build docs from the core repo and use those, instead of us always having to update that repo with the current Typedoc commands.
eonarheim pushed a commit that referenced this issue Apr 18, 2017
Related #777

## Changes:

- On local builds, use local package version placeholder for quick builds
- On CI builds, use GitHub release version. Fails the build if API request fails.

This change allows us to remove all specific versioning from the repository, relying on GitHub as the source of truth for all releases. As a side effect, dist files get a better version anyway--previously they only had the latest release (v0.10.0) and date. Now they will get the commit and Travis build number.
@jedeen jedeen added this to the vNext milestone Apr 29, 2017
kamranayub added a commit that referenced this issue Aug 12, 2017
@TheDocTrier
Copy link

@kamranayub Question having to do with 8eec705 : how do you,

use local package version placeholder for quick builds

I'm fairly new to TypeScript, Node, etc. and I was hoping that I could use the git repository for one of my dependencies so I could make changes to the code base as I work on a game if necessary. When I try to install/add the local copy as a dependency, npm complains about no version being present in the package.json.

I ended up adding an arbitrary version to package.json and it seemed to install correctly. Is this the preferred method, or did I misinterpret the instructions? Also, this might be good information to include in the docs unless I just missed something.

I'm not too familiar with the etiquette around here, so I'll end with "Thank You".

@kamranayub
Copy link
Member Author

kamranayub commented Feb 28, 2018

@Tankobot Good question!

use local package version placeholder for quick builds

This is what that "local" string does in the package.json for local builds--it skips the checking of versions from GitHub since that's only needed for CI. It does cause the issue you are seeing, though 👎 We could experiment with different version strings, like 0.0.1-local to see if that helps.

Otherwise, a couple other approaches may work:

Using npm

With NPM, I believe you can use a feature of using the Git URL as the package name:

npm install <git repo url>

However, the issue you mentioned might still occur, I haven't tested that. But, if you wanted, you can reference your own fork of Excalibur and reference a branch where you've made the modification to the package.json. The URL would be the URL to the tree of that branch, like https://github.com/excaliburjs/Excalibur/tree/918-packed-spritesheet

This is probably similar (or the same) as what you did. Not ideal 😢

Using submodules

Typically the way we've set up local games and anticipate modifying Excalibur is by using Git submodules.

Basically, you would run the following in your game repository to set up Excalibur as a submodule:

git submodule add https://github.com/excaliburjs/Excalibur

The Git URL can also just be your fork of Excalibur.

This will create a new .gitmodules file and create a directory for Excalibur. Working with submodules can be weird and one thing they do is show as "dirty" in git status if you've made any changes to the files inside the module. This is annoying because typically we go into the submodule, then do git checkout master then git checkout -b my-new-branch for changes we want to make.

So I'd suggest adding the following to your .gitmodules file:

ignore = dirty
branch = my-new-branch

You can see an example of this set up in our latest game:

https://github.com/excaliburjs/ludum-38/blob/master/.gitmodules

The other thing to remember is when cloning a repo that has modules, you need to run:

git submodule update

To get the latest module. This also applies when you pull new changes and someone updated the submodule reference. For more about that: https://chrisjean.com/git-submodules-adding-using-removing-and-updating/

I agree we should add this info to the docs. If you get it working and feel comfortable, we'd love to have a PR into the docs. Otherwise, if I can synthesize this into coherent docs, I can add a guide.

@jedeen jedeen modified the milestones: vNext, 0.18.0 Release Mar 31, 2018
@jedeen jedeen modified the milestones: 0.18.0 Release, 0.19.0 Release Jul 20, 2018
@jedeen jedeen modified the milestones: 0.19.0 Release, 0.20.0 Release Oct 13, 2018
@jedeen jedeen modified the milestones: 0.20.0 Release, 0.21.0 Release Dec 11, 2018
@jedeen jedeen modified the milestones: 0.21.0 Release, 0.22.0 Release Dec 21, 2018
@jedeen jedeen removed this from the 0.22.0 Release milestone Apr 6, 2019
@jedeen jedeen added this to the 0.23.0 Release milestone Apr 6, 2019
@jedeen jedeen modified the milestones: 0.24.0 Release, 0.25.0 Nov 24, 2019
@jedeen jedeen added the core team This issue should be done by an Excalibur core member label Apr 24, 2020
@github-actions
Copy link

This issue hasn't had any recent activity lately and is being marked as stale automatically.

@github-actions github-actions bot added the stale This issue or PR has not had any activity recently label Dec 27, 2020
@jedeen jedeen modified the milestones: 0.25.0 Release, 0.26.0 Release Oct 9, 2021
@eonarheim eonarheim removed this from the 0.26.0 Release milestone Feb 1, 2022
@eonarheim
Copy link
Member

Closing for now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core team This issue should be done by an Excalibur core member stale This issue or PR has not had any activity recently tools
Projects
None yet
Development

No branches or pull requests

4 participants