Commit Graph

58 Commits

Author SHA1 Message Date
Evan Simkowitz
8ec3c3f330
Update Go toolchain to 1.23.4 (#1395)
Because Electron now has a macOS 11 minimum supported version, we have
no blockers to adopting the latest Go toolchain. This also lets us use
the new `range` features in Go, among other things.
2024-12-05 12:13:45 -08:00
Evan Simkowitz
59c570ddcf
Hopefully last fix to the winget publish job (#1337) 2024-11-21 14:14:32 -08:00
Evan Simkowitz
7c6fa91016
Fix copyfiles for docsite (#1321) 2024-11-19 14:15:11 -08:00
Evan Simkowitz
159c10ee9b
Run deploy-docsite check when Taskfile is modified (#1307)
Now that deploy-docsite depends on the Taskfile, we need to gate
Taskfile changes on it.
2024-11-15 16:16:12 -08:00
Evan Simkowitz
3b117805fe
Move docsite build scripts to Taskfile, make the electron tasks depend on them (#1298)
This adds the new tasks `docsite:start`, `docsite:build:public`,
`docsite:build:embedded`, `storybook:build`, and `copyfiles:*:*` to
Taskfile.

It also updates the "Build Helper" and "Docsite and Storybook CI/CD"
workflows to use these new tasks.

It also makes the docsite embedded build a dependency of the electron
tasks, ensuring that the embedded docsite is included when building
locally.

Tested and confirms this works on Windows
2024-11-15 12:19:31 -08:00
Evan Simkowitz
e5f98c6475
Update our build workflows to use NodeJS 22 (#1285)
NodeJS 20 is almost EOL so I'm updating our workflows to use NodeJS 22.
This does not change anything about our app, which will still use NodeJS
20 until Electron shifts away from it. NodeJS 22 is fully
backwards-compatible with NodeJS 20 so there's no issue from a testing
standpoint.
2024-11-13 21:06:48 -08:00
Evan Simkowitz
6021ef0fd6
Accept package agreements for winget install (#1271) 2024-11-12 10:37:45 -08:00
Evan Simkowitz
28d95878eb
Set testdriver to not run on unnecessary pushes (#1267) 2024-11-11 16:06:16 -08:00
Evan Simkowitz
b24e2d917d
Use merge-gatekeeper (#1245) 2024-11-08 11:29:25 -08:00
Evan Simkowitz
02c8827483
Add dummy workflow so that deploy-docsite is treated as a status check (#1244) 2024-11-08 11:15:37 -08:00
Evan Simkowitz
e478a86bf5
Remove unnecessary copy (#1220) 2024-11-06 11:59:32 -08:00
Evan Simkowitz
ed8d3c179c
Test relative assets for storybook (#1219) 2024-11-06 11:56:49 -08:00
Evan Simkowitz
437e4e8c6e
Set base url for storybook using env var (#1218) 2024-11-06 11:47:46 -08:00
Evan Simkowitz
b306eab0d8
Consolidate docsite/storybook CI/CD workflows (#1217) 2024-11-06 11:36:08 -08:00
Evan Simkowitz
66675fc3e5
Final assets fix? (#1216) 2024-11-06 11:25:35 -08:00
Evan Simkowitz
ea3e12875d
Copy assets from repo into build output (#1215) 2024-11-06 11:17:47 -08:00
Evan Simkowitz
516029e508
Move storybook-static assets to static root (#1214) 2024-11-06 10:57:40 -08:00
Evan Simkowitz
efd8ad7254
Remove bad working directory for docsite CD (#1212) 2024-11-06 10:48:31 -08:00
Evan Simkowitz
edb3290349
Move docsite to main repo (#1204)
## Summary

We are moving our docsite to this repo for better coordination.

## What's changed?

- The docsite codebase is now in docs/
- The docsite will replace storybook as the published GitHub Pages site
for this repo
- Storybook will now be hosted at https://docs.waveterm.dev/storybook
- A new CI workflow will validate any changes to Storybook or the
docsite
- A combined CD workflow will build and deploy Storybook and the docsite
as a single artifact
- The Build Helper workflow will now build an embedded version of the
docsite before building the app, ensuring the docsite version it has is
always the latest
2024-11-06 10:45:21 -08:00
Evan Simkowitz
7476c2f700
Install winget before installing wingetcreate in publish workflow (#1203) 2024-11-05 10:30:44 -08:00
Evan Simkowitz
a170e2c80c
Fix WinGet version bump (#1165)
Use WinGet to install `wingetcreate`, rather than using
Invoke-WebRequest
2024-10-28 22:45:13 -07:00
Mike Sawka
e419b7f99e
fix builder 2 (#1150) 2024-10-26 12:18:27 -07:00
Mike Sawka
76bb374d52
add needs: runbuild (#1149) 2024-10-26 11:40:25 -07:00
Evan Simkowitz
d66380d88b
Remove release creation race in build helper (#1133)
There was a race condition in the Build Helper where if multiple runners
got to the "Create draft release" step at the same time, we could get
duplicate releases created. Now, each of the build runners will upload
the artifacts to the workflow artifact feed. Then, a single runner will
create the draft release.
2024-10-24 18:42:48 -07:00
Evan Simkowitz
2da51d2c22
Remove snapcraft install action that uses deprecated Node version (#1123) 2024-10-24 12:47:11 -07:00
Evan Simkowitz
e6f9ab7336
Fix task naming to avoid conflicts (#1122) 2024-10-24 12:36:55 -07:00
Evan Simkowitz
be8ae0ef51
Use a different action to download release (#1121) 2024-10-24 12:03:40 -07:00
Evan Simkowitz
8d79539a50
Fix bugs in electron-builder and build-helper (#1119) 2024-10-24 11:20:25 -07:00
Evan Simkowitz
3bd9249e81
Add steps to publish to Snapcraft (#1102)
Draft until our Snap package is approved for classic confinement:
https://forum.snapcraft.io/t/classic-confinement-request-for-waveterm/43562
2024-10-23 22:24:33 -07:00
Evan Simkowitz
8b2805b7fb
Add step to bump Winget package version on publish (#1103)
This will only bump the version when we publish a latest release, not a
beta one. It'll automatically create a PR to the [winget-pkgs
](https://github.com/microsoft/winget-pkgs) repo.

Draft until my New Package PR gets merged:
https://github.com/microsoft/winget-pkgs/pull/185133
2024-10-23 14:04:16 -07:00
Evan Simkowitz
81a8a7f3eb
Snap support (#1095)
Adds Snap support, though I'm still waiting to hear back from the
Snapcraft team about getting our package listed.

closes #1092
2024-10-21 18:13:19 -07:00
Evan Simkowitz
6f19a3effa
Update run name for manual dispatch (#1090) 2024-10-21 12:55:24 -07:00
Evan Simkowitz
f41a844a38
Attempt to fix chrome-sandbox permissions issue on Linux (#1089)
Also allows for test runs of build-helper, which will not upload to
staging
2024-10-21 12:52:13 -07:00
Ian Jennings
123b627640
TestDriver v4 (#865)
This PR upgrades the TestDriver tests to v4.

Some relevant updates on  `v4` for y'all:
- Our AI will pick up the job within ~2 minutes
- Tests are 40% faster (with room for more improvement through turbo
mode) and significantly more accurate
- New `/generate` features enable the AI to create it's own tests
- Smarter `/explore` features, this is how we generated your onboarding
test
- New `key:` config in our `action` allows you to post videos to your
own account
- New `createPR:` config in our `action` will automatically create PRs
from test output
- New [documentation](https://docs.testdriver.ai/reference/yml-schema).
- VMs are now on Windows
- Our best practice have been updated so we don't act as a build server
anymore. Now,[ we download your artifact from
GitHub](https://github.com/wavetermdev/waveterm/actions/runs/11276657325/workflow?pr=865#L96-L179)
and test that. I cloned your "build and upload exe" action to do this,
but we can link them together in the future.


[![wavetermdev/waveterm/refs/pull/865/merge](https://replayable-api-production.herokuapp.com/replay/6707f12167f936f4742af056/gif?shareKey=ecw0VAHvh6k2gCJDqFQew)](https://app.dashcam.io/replay/6707f12167f936f4742af056?share=ecw0VAHvh6k2gCJDqFQew)

Watch
[wavetermdev/waveterm/refs/pull/865/merge](https://app.dashcam.io/replay/6707f12167f936f4742af056?share=ecw0VAHvh6k2gCJDqFQew)
on Dashcam

---------

Co-authored-by: Evan Simkowitz <esimkowitz@users.noreply.github.com>
2024-10-17 19:09:41 -05:00
Evan Simkowitz
b8e03e9628
Re-enable go and zig actions in codeql pipeline (#990)
This was causing the builds for the javascript-typescript job to actually run longer because Go was still required to generate the bindings
2024-10-08 17:52:50 -04:00
Evan Simkowitz
62a20b2dd9
Don't update all brew dependencies (#950) 2024-10-03 20:43:58 -07:00
Evan Simkowitz
74cda378f8
Embed static copy of docsite for help view (#949)
This will take the latest artifact from the waveterm-docs repo and embed
it in the app binary. When the help view is launched, it will be served
from our backend. If the embedded copy doesn't exist, such as in
unpackaged versions of the app or in locally packaged versions, it will
use the hosted site instead.

There is a sibling PR in the docs repository to build the embedded
version of the app (strips out some external links, removes Algolia
DocSearch, updates the baseUrl)
https://github.com/wavetermdev/waveterm-docs/pull/46
2024-10-03 20:28:05 -07:00
Evan Simkowitz
6ffa421744
Storybook page, exclude Jotai from dependabot, use NodeJS 20 for builds (#868) 2024-09-26 14:17:52 -07:00
Evan Simkowitz
411bb44e11
Switch to macos-latest runner now that it is ARM (#851) 2024-09-25 12:26:04 -07:00
Evan Simkowitz
76f4ec641c
Try using Zig instead (#831) 2024-09-24 20:26:04 -07:00
Evan Simkowitz
e58e791b13
Use composite action for setup-musl-gcc (#829) 2024-09-24 19:53:57 -07:00
Evan Simkowitz
e7a510c0d6
Make musl-gcc from scratch (#828) 2024-09-24 19:41:58 -07:00
Evan Simkowitz
b83589f20e
Attempt using musl-gcc instead of Glibc (#826) 2024-09-24 19:14:07 -07:00
Evan Simkowitz
78f838439a
prevent running this workflow on unprotected branches 2024-09-20 09:58:35 -07:00
Evan Simkowitz
b7d01c0403
Add automated release flow (#394)
## New release workflow

Build Helper will now automatically create a draft GitHub Release after
it finishes its builds. It will upload a copy of the build artifacts to
this release for easy access.

When a version is ready to be published, edit the GitHub Release and
publish it. This will trigger a workflow to publish the artifacts to our
releases feed.

## Moved artifacts scripts to Taskfile

The scripts formerly located at `scripts/artifacts` have been moved to
the Taskfile. They can now be found at `artifacts:*`.

## Moved releases readme to `RELEASES.md`

Updated the releases readme with step-by-step instructions and moved it
from `scripts/artifacts` to `RELEASES.md`

## Created new AWS identities for artifact upload and publishing

This narrows the scopes of the AWS identities used by the workflows to
upload and publish artifacts. The Build Helper workflow now only has
permission to put files into the artifacts bucket. The Publish Release
workflow only has permission to get files from the artifacts bucket and
put them into the releases bucket.
2024-09-18 12:29:47 -07:00
Evan Simkowitz
6a7fadc420
Evan/v (#392)
Co-authored-by: wave-builder[bot] <181805596+wave-builder[bot]@users.noreply.github.com>
2024-09-17 13:37:52 -07:00
Evan Simkowitz
5b7535d08f
Add release channels (#385)
## New release flow

1. Run "Bump Version" workflow with the desired version bump and the
prerelease flag set to `true`. This will push a new version bump to the
target branch and create a new git tag.
    - See below for more info on how the version bumping works.
2. A new "Build Helper" workflow run will kick off automatically for the
new tag. Once it is complete, test the new build locally by downloading
with the [download
script](https://github.com/wavetermdev/thenextwave/blob/main/scripts/artifacts/download-staged-artifact.sh).
3. Release the new build using the [publish
script](https://github.com/wavetermdev/thenextwave/blob/main/scripts/artifacts/publish-from-staging.sh).
This will trigger electron-updater to distribute the package to beta
users.
4. Run "Bump Version" again with a release bump (either `major`,
`minor`, or `patch`) and the prerelease flag set to `false`.
6. Release the new build to all channels using the [publish
script](https://github.com/wavetermdev/thenextwave/blob/main/scripts/artifacts/publish-from-staging.sh).
This will trigger electron-updater to distribute the package to all
users.

## Change Summary

Creates a new "Bump Version" workflow to manage versioning and tag
creation.

Build Helper is now automated.

### Version bumps

Updates the `version.cjs` script so that an argument can be passed to
trigger a version bump. Under the hood, this utilizes NPM's `semver`
package.

If arguments are present, the version will be bumped.
If only a single argument is given, the following are valid inputs:
    - `none`: No-op.
    - `patch`: Bumps the patch version.
    - `minor`: Bumps the minor version.
    - `major`: Bumps the major version.
    - '1', 'true': Bumps the prerelease version.
If two arguments are given, the first argument must be either `none`,
`patch`, `minor`, or `major`. The second argument must be `1` or `true`
to bump the prerelease version.

### electron-builder

We are now using the release channels support in electron-builder. This
will automatically detect the channel being built based on the package
version to determine which channel update files need to be generated.
See
[here](https://www.electron.build/tutorials/release-using-channels.html)
for more information.

### Github Actions

#### Bump Version

This adds a new "Bump Version" workflow for managing versioning and
queuing new builds. When run, this workflow will bump the version,
create a new tag, and push the changes to the target branch. There is a
new dropdown when queuing the "Bump Version" workflow to select what
kind of version bump to perform. A bump must always be performed when
running a new build to ensure consistency.

I had to create a GitHub App to grant write permissions to our main
branch for the version bump commits. I've made a separate workflow file
to manage the version bump commits, which should help prevent tampering.
Thanks to using the GitHub API directly, I am able to make these commits
signed!

#### Build Helper

Build Helper is now triggered when new tags are created, rather than
being triggered automatically. This ensures we're always creating
artifacts from known checkpoints.

### Settings

Adds a new `autoupdate:channel` configuration to the settings file. If
unset, the default from the artifact will be used (should correspond to
the channel of the artifact when downloaded).

## Future Work

I want to add a release workflow that will automatically copy over the
corresponding version artifacts to the release bucket when a new GitHub
Release is created.

I also want to separate versions into separate subdirectories in the
release bucket so we can clean them up more-easily.

---------

Co-authored-by: wave-builder <builds@commandline.dev>
Co-authored-by: wave-builder[bot] <181805596+wave-builder[bot]@users.noreply.github.com>
2024-09-17 13:10:35 -07:00
Evan Simkowitz
87d3f8d88d
add bump version workflow 2024-09-16 23:26:50 -07:00
Evan Simkowitz
e7b99d165a
Update secrets to the new Apple Developer account creds (#384) 2024-09-16 23:10:04 -07:00
Evan Simkowitz
a2695e8c08
Set up Windows build pipeline (#292)
This adds a new job to the Build Helper pipeline for building for
Windows. This includes code signing via DigiCert. Right now, we can only
build for x64 on Windows as wavesrv fails to build for arm64 in the
default runner and the Windows ARM runner images are missing a bunch of
tooling.

This also adds new separated arm64 and x64 for macOS for those who don't
want to use the universal binary.

This also improves the general code quality of the Taskfile.yml and the
build-helper.yml files.
2024-08-30 10:13:40 -07:00