Skip to content

Commit

Permalink
Merge pull request #1403 from nextstrain/chore/cleanup-2
Browse files Browse the repository at this point in the history
  • Loading branch information
ivan-aksamentov authored Feb 13, 2024
2 parents 9f0ee61 + b9ef161 commit 611e059
Show file tree
Hide file tree
Showing 817 changed files with 55 additions and 58 deletions.
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
version: 2
updates:
- package-ecosystem: "npm"
directory: "/packages_rs/nextclade-web/"
directory: "/packages/nextclade-web/"
schedule:
interval: "daily"
allow:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ jobs:
run: |
export PATH="${PATH}:${HOME}/bin"
version=$(dasel select -p toml -s ".package.version" -f "packages_rs/nextclade/Cargo.toml")
version=$(dasel select -p toml -s ".package.version" -f "packages/nextclade/Cargo.toml")
if [[ "$version" =~ (rc|beta|alpha) ]]; then
export DATA_FULL_DOMAIN="https://data.master.clades.nextstrain.org/v3"
fi
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/web.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ jobs:
path: |
.build/
.cache/docker/.cargo
packages_rs/nextclade-web/.build/docker
packages/nextclade-web/.build/docker
key: cache-v1-cargo-${{ runner.os }}-wasm32-unknown-unknown-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
cache-v1-cargo-${{ runner.os }}-wasm32-unknown-unknown-${{ hashFiles('**/Cargo.lock') }}
Expand All @@ -94,9 +94,9 @@ jobs:
uses: actions/cache@v4
with:
path: |
packages_rs/nextclade-web/.build/production/tmp/cache
packages_rs/nextclade-web/.cache
packages_rs/nextclade-web/node_modules
packages/nextclade-web/.build/production/tmp/cache
packages/nextclade-web/.cache
packages/nextclade-web/node_modules
key: cache-v1-web-${{ runner.os }}-wasm32-unknown-unknown-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
cache-v1-web-${{ runner.os }}-wasm32-unknown-unknown-${{ hashFiles('**/yarn.lock') }}
Expand Down Expand Up @@ -144,7 +144,7 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: out
path: "packages_rs/nextclade-web/.build/production/web"
path: "packages/nextclade-web/.build/production/web"


deploy-web:
Expand Down Expand Up @@ -191,7 +191,7 @@ jobs:
uses: actions/download-artifact@v4
with:
name: "out"
path: "packages_rs/nextclade-web/.build/production/web"
path: "packages/nextclade-web/.build/production/web"

- name: "Install deploy dependencies"
run: |
Expand All @@ -218,7 +218,7 @@ jobs:
git config user.email "${{ secrets.GIT_USER_EMAIL }}"
git config user.name "${{ secrets.GIT_USER_NAME }}"
pushd packages_rs/nextclade-web >/dev/null
pushd packages/nextclade-web >/dev/null
export version=$(node -e "\
const pkg = require('./package.json'); \
Expand Down
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
/e2e/cli/snapshots/
/e2e/cli/tmp/
/example-data/
/packages_rs/*/target/
/packages_rs/nextclade-web/src/gen
/packages/*/target/
/packages/nextclade-web/src/gen
/paper/paper.pdf
/paper/preprint.pdf
/paper/tex2pdf*
Expand Down
5 changes: 2 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
[workspace]

members = [
"packages_rs/*",
"packages/*",
]

exclude = [
"packages_rs/3rdparty",
"packages_rs/tree-builder-prototype"
"packages/3rdparty",
]
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ by Nextstrain team

<a href="packages/web/package.json">
<img
src="https://img.shields.io/github/package-json/v/nextstrain/nextclade/master/packages_rs/nextclade-web?label=web&logo=npm"
src="https://img.shields.io/github/package-json/v/nextstrain/nextclade/master/packages/nextclade-web?label=web&logo=npm"
alt="package.json version"
/>
</a>
Expand Down
14 changes: 7 additions & 7 deletions docker/dev
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,10 @@ export FILES_TO_WATCH="\
-w 'Cargo.lock' \
-w 'Cargo.toml' \
-w 'clippy.toml' \
-w 'packages_rs/nextclade-web/src' \
-w 'packages_rs/nextclade-web/Cargo.toml' \
-w 'packages_rs/nextclade/src' \
-w 'packages_rs/nextclade/Cargo.toml' \
-w 'packages/nextclade-web/src' \
-w 'packages/nextclade-web/Cargo.toml' \
-w 'packages/nextclade/src' \
-w 'packages/nextclade/Cargo.toml' \
-w 'rust-toolchain.toml' \
-w 'rustfmt.toml' \
"
Expand All @@ -129,7 +129,7 @@ export FILES_TO_IGNORE="\
-i '.cache' \
-i '.vscode' \
-i 'target/' \
-i 'packages_rs/nextclade-web/src/gen/' \
-i 'packages/nextclade-web/src/gen/' \
"

export LINT_FIX="--fix --allow-staged"
Expand Down Expand Up @@ -471,11 +471,11 @@ elif [ "${BUILD}" == "1" ]; then
elif [ "${SMOKE_TEST}" == "1" ]; then
COMMAND="./tests/run-smoke-tests 'cargo run -q --target-dir='${BUILD_DIR_REL}' ${RUST_TARGET} ${RELEASE} --bin=nextclade'"
elif [ "${WASM}" == "1" ]; then
COMMAND="bash -c \"set -euo pipefail && cd packages_rs/nextclade-web && yarn install && yarn wasm-${RELEASE}\""
COMMAND="bash -c \"set -euo pipefail && cd packages/nextclade-web && yarn install && yarn wasm-${RELEASE}\""
elif [ "${WEB}" == "1" ]; then
PORTS="-p 3000:3000"
COMMAND=${COMMAND:=yarn install && yarn ${RELEASE}}
COMMAND="bash -c \"set -euo pipefail && cd packages_rs/nextclade-web && ${COMMAND}\""
COMMAND="bash -c \"set -euo pipefail && cd packages/nextclade-web && ${COMMAND}\""
elif [ "${TEST}" == "1" ]; then
PRETTY_TEST="( grep --color=always --line-buffered -vP \"running.*tests|\x1b\[32m.\x1b\(B\x1b\[m|^$|test result|TEST START\" || true )"
COMMAND="cargo test --color=always -q --target-dir='${BUILD_DIR_REL}' ${RUST_TARGET} ${TEST_FLAGS} ${*:-} -- --nocapture --color=always | ${PRETTY_TEST} ${SUCCESS_OR_FAILURE}"
Expand Down
14 changes: 7 additions & 7 deletions docs/dev/developer-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ Install Node.js version 14+ (latest LTS release is recommended), by either downl
5. Install NPM dependencies (once)
```bash
cd packages_rs/nextclade-web
cd packages/nextclade-web
yarn install
```
Expand All @@ -220,11 +220,11 @@ Install Node.js version 14+ (latest LTS release is recommended), by either downl
6. Build the WebAssembly module

```bash
cd packages_rs/nextclade-web
cd packages/nextclade-web
yarn wasm-prod
```

This step might take a lot of time. The WebAssembly module and accompanying Typescript code should be been generated into `packages_rs/nextclade-web/src/gen/`. The web application should be able to find it there.
This step might take a lot of time. The WebAssembly module and accompanying Typescript code should be been generated into `packages/nextclade-web/src/gen/`. The web application should be able to find it there.

Repeat this step every time you are touching Rust code.

Expand All @@ -235,7 +235,7 @@ Install Node.js version 14+ (latest LTS release is recommended), by either downl
The development version can be built using:
```bash
cd packages_rs/nextclade-web
cd packages/nextclade-web
yarn dev
```
Expand All @@ -250,7 +250,7 @@ Install Node.js version 14+ (latest LTS release is recommended), by either downl
Open `http://localhost:8080/` in the browser.
The resulting HTML, CSS and JS files should be available under `packages_rs/nextclade-web/.build/production/web`.
The resulting HTML, CSS and JS files should be available under `packages/nextclade-web/.build/production/web`.
Production build does not have automatic rebuild and reload. You need to do full rebuild on every code change.
Expand Down Expand Up @@ -321,7 +321,7 @@ For routine development, it is recommended to configure your text editor to see
The web app is linted using [eslint](https://github.com/eslint/eslint) and [tsc](https://www.typescriptlang.org/docs/handbook/compiler-options.html) as a part of development command, but the same lints also be run separately:
```bash
cd packages_rs/nextclade-web
cd packages/nextclade-web
yarn lint
```
Expand All @@ -340,7 +340,7 @@ cargo fmt --all
Typescript:
```bash
cd packages_rs/nextclade-web
cd packages/nextclade-web
yarn format:fix
```
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ export function getGeneMapDimensions(cdsSegments: CdsSegment[], isGlobal: boolea
geneStrandOffset += GENE_STRAND_SPACING
} else if (hasStrands) {
geneMapHeight += geneStrandOffset + GENE_STRAND_SPACING
} else if (hasFrames) {
geneMapHeight += geneFrameOffset * 3
} else {
geneMapHeight += geneFrameOffset * 3
}
Expand Down
Loading

0 comments on commit 611e059

Please sign in to comment.