Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .github/workflows/bazel-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ on:
push:
branches:
- develop
pull_request: {}
jobs:
build-gui:
name: Run bazel GUI build
Expand Down
8 changes: 1 addition & 7 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,7 @@

name: Changelog
on:
pull_request:
types:
- labeled
- unlabeled
- synchronize
- opened
- reopened
workflow_dispatch: {}
jobs:
changelog:
name: Changelog
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/engine-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ on:
push:
branches:
- develop
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-engine-pull-request
Expand Down
9 changes: 0 additions & 9 deletions .github/workflows/enso4igv.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,6 @@ name: Enso Language Support for VSCode, IGV, NetBeans
on:
push:
branches: [develop]
pull_request:
branches: [develop]
paths:
- ".github/workflows/enso4igv.yml"
- "tools/enso4igv/**/*"
- "engine/**/*"
- "lib/java/**/*"
- "lib/scala/**/*"
- "build.sbt"

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-enso4igv
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/formatting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ name: Code Formatting Check
on:
push:
branches: [develop, "release/*"]
pull_request:
branches: ["*"]

env:
# Please ensure that this is in sync with graalVersion in build.sbt
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/gui-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ on:
push:
branches:
- develop
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-gui-pull-request
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/ide-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ on:
push:
branches:
- develop
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-ide-pull-request
Expand Down
54 changes: 54 additions & 0 deletions .github/workflows/macos-bazel-dmg.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Bazel macOS DMG build (temporary)

on:
workflow_dispatch: {}
pull_request: {}

jobs:
build-macos-dmg:
name: Run bazel DMG build
runs-on:
- self-hosted
- macOS
steps:
- uses: bazel-contrib/[email protected]
with:
bazelisk-version: 1.x
bazelisk-cache: true
bazelrc: build --remote_cache=grpcs://${{ vars.ENSO_BAZEL_CACHE_URI }} --remote_cache_header="authorization=Basic ${{ secrets.ENSO_BAZEL_CACHE_TOKEN }}"
- uses: actions/checkout@v4
- name: Expose env variables
run: |
cat << END > app/common/.env.production
ENSO_IDE_ENVIRONMENT="${{ vars.ENSO_CLOUD_ENVIRONMENT }}"
ENSO_IDE_API_URL="${{ vars.ENSO_CLOUD_API_URL }}"
ENSO_IDE_CHAT_URL="${{ vars.ENSO_CLOUD_CHAT_URL }}"
ENSO_IDE_COGNITO_DOMAIN="${{ vars.ENSO_CLOUD_COGNITO_DOMAIN }}"
ENSO_IDE_COGNITO_REGION="${{ vars.ENSO_CLOUD_COGNITO_REGION }}"
ENSO_IDE_COGNITO_USER_POOL_ID="${{ vars.ENSO_CLOUD_COGNITO_USER_POOL_ID }}"
ENSO_IDE_COGNITO_USER_POOL_WEB_CLIENT_ID="${{ vars.ENSO_CLOUD_COGNITO_USER_POOL_WEB_CLIENT_ID }}"
ENSO_IDE_GOOGLE_ANALYTICS_TAG="${{ vars.ENSO_CLOUD_GOOGLE_ANALYTICS_TAG }}"
ENSO_IDE_SENTRY_DSN="${{ vars.ENSO_CLOUD_SENTRY_DSN }}"
ENSO_IDE_STRIPE_KEY="${{ vars.ENSO_CLOUD_STRIPE_KEY }}"
ENSO_IDE_AG_GRID_LICENSE_KEY="${{ vars.ENSO_AG_GRID_LICENSE_KEY }}"
ENSO_IDE_MAPBOX_API_TOKEN="${{ vars.ENSO_MAPBOX_API_TOKEN }}"
ENSO_IDE_COMMIT_HASH="${{ github.sha }}"
ENSO_IDE_VERSION="SNAPSHOT-${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}"
ENSO_IDE_CLOUD_BUILD="false"
END
- name: Build DMG package
run: bazel build --sandbox_debug --verbose_failures --subcommands //app/electron-client:dist
env:
DEBUG: electron-builder
ELECTRON_BUILDER_DEBUG: "1"
- name: Get DMG build output location
id: get_bazel_output
run: |
OUTPUT_SYMLINK=$(bazel cquery --output=files //app/electron-client:dist)
BAZEL_OUTPUT=$(realpath "$OUTPUT_SYMLINK")
echo "location=$BAZEL_OUTPUT" >> $GITHUB_OUTPUT
- uses: actions/upload-artifact@v4
with:
name: ide-macos-dmg
path: ${{ steps.get_bazel_output.outputs.location }}
if-no-files-found: error
1 change: 0 additions & 1 deletion .github/workflows/std-libs-labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ on:
push:
branches:
- develop
pull_request: {}
workflow_dispatch: {}
workflow_call: {}
permissions:
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/wasm-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ on:
push:
branches:
- develop
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-wasm-pull-request
Expand Down
13 changes: 12 additions & 1 deletion BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,11 @@ config_setting(
visibility = ["//visibility:public"],
)

# This can use `ts_config` rule because the file list is empty.
ts_config(
name = "tsconfig",
src = "tsconfig.json",
visibility = [":__subpackages__"],
visibility = ["//visibility:public"],
)

write_source_files(
Expand All @@ -31,7 +32,17 @@ write_source_files(
"//app/rust-ffi:write_wasm_dist",
"//app/ydoc-shared:write_ast_codegen",
"//app/gui:write_icon_metadata",
"//app/gui:write_tsconfigs",
"//app/table-expression:write_parser_codegen",
# Generated tsconfig files
"//app/common:write_tsconfigs",
"//app/electron-client:write_tsconfigs",
"//app/lang-markdown:write_tsconfigs",
"//app/lezer-markdown:write_tsconfigs",
"//app/project-manager-shim:write_tsconfigs",
"//app/table-expression:write_tsconfigs",
"//app/ydoc-server:write_tsconfigs",
"//app/ydoc-shared:write_tsconfigs",
],
)

Expand Down
58 changes: 50 additions & 8 deletions app/common/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,26 +1,37 @@
load("@aspect_bazel_lib//lib:write_source_files.bzl", "write_source_files")
load("@aspect_rules_js//npm:defs.bzl", "npm_package")
load("@aspect_rules_ts//ts:defs.bzl", "ts_config", "ts_project")
load("@aspect_rules_ts//ts:defs.bzl", "ts_project")
load("@npm//:defs.bzl", "npm_link_all_packages", "npm_link_targets")
load("//:bazel_scripts/ts_config.bzl", "write_tsconfig")

npm_link_all_packages(name = "node_modules")

ts_config(
name = "tsconfig",
src = "tsconfig.json",
deps = ["//:tsconfig"],
)

ts_project(
name = "tsc",
srcs = glob([
"src/**/*.ts",
]) + ["src/text/english.json"],
allow_js = True,
composite = True,
declaration = True,
extends = "//:tsconfig",
no_emit = False,
out_dir = "dist",
resolve_json_module = True,
root_dir = "src",
tsconfig = ":tsconfig",
tsconfig = {
"compilerOptions": {
"lib": [
"DOM",
"es2023",
],
"composite": True,
"allowJs": True,
"checkJs": True,
"noEmit": False,
"resolveJsonModule": True,
},
},
validate = select({
"@platforms//os:windows": False,
"//conditions:default": True,
Expand All @@ -36,3 +47,34 @@ npm_package(
],
visibility = ["//visibility:public"],
)

write_tsconfig(
name = "tsconfig_generated",
out = "tsconfig.json",
allow_js = True,
config = {
"compilerOptions": {
"lib": [
"DOM",
"es2023",
],
"allowJs": True,
"checkJs": True,
"skipLibCheck": False,
"noEmit": False,
"resolveJsonModule": True,
"outDir": "dist",
"rootDir": "src",
},
},
extends = "//:tsconfig",
files = glob(["src/**/*.ts"]) + ["src/text/english.json"],
resolve_json_module = True,
)

write_source_files(
name = "write_tsconfigs",
files = {"tsconfig.json": ":tsconfig_generated"},
suggested_update_target = "//:write_all",
visibility = ["//visibility:public"],
)
50 changes: 43 additions & 7 deletions app/common/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,51 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"lib": ["DOM", "es2023"],
"allowJs": true,
"checkJs": true,
"skipLibCheck": false,
"lib": ["DOM", "es2023"],
"noEmit": false,
"resolveJsonModule": true,
"outDir": "dist",
"rootDir": "src"
"resolveJsonModule": true,
"rootDir": "src",
"skipLibCheck": false
},
"include": ["./src", "./src/text/english.json"],
"exclude": []
"extends": "../../tsconfig.json",
"files": [
"./src/accessToken.ts",
"./src/constants.ts",
"./src/download.ts",
"./src/options.ts",
"./src/services/Backend.ts",
"./src/services/Backend/Category.ts",
"./src/services/Backend/__test__/projectExecution.test.ts",
"./src/services/Backend/ensoPath.ts",
"./src/services/Backend/projectExecution.ts",
"./src/services/Backend/remoteBackendPaths.ts",
"./src/services/Backend/types.ts",
"./src/services/Backend/utilities.ts",
"./src/services/HttpClient.ts",
"./src/services/LocalBackend.ts",
"./src/services/ProjectManager/ProjectManager.ts",
"./src/services/ProjectManager/types.ts",
"./src/services/RemoteBackend.ts",
"./src/services/RemoteBackend/ids.ts",
"./src/services/__test__/Backend.test.ts",
"./src/text.ts",
"./src/utilities/__test__/nameValidation.test.ts",
"./src/utilities/async.ts",
"./src/utilities/data/__tests__/iter.test.ts",
"./src/utilities/data/dateTime.ts",
"./src/utilities/data/iter.ts",
"./src/utilities/data/newtype.ts",
"./src/utilities/data/object.ts",
"./src/utilities/data/opt.ts",
"./src/utilities/data/result.ts",
"./src/utilities/detect.ts",
"./src/utilities/errors.ts",
"./src/utilities/file.ts",
"./src/utilities/nameValidation.ts",
"./src/utilities/permissions.ts",
"./src/utilities/uniqueString.ts",
"./src/text/english.json"
]
}
Loading
Loading