Update with Theo's Gitea

Signed-off-by: T-Hax <>
This commit is contained in:
T-Hax 2023-05-10 18:42:48 +00:00
parent 522318058b
commit 90dccbf1ae
4 changed files with 42 additions and 20 deletions

View file

@ -1,2 +1,17 @@
#!/bin/bash #!/bin/bash
export GITEA_AUTH_TOKEN=
REGISTRY_1_USER="user"
REGISTRY_1_DOMAIN="domain.com"
REGISTRY_1_GITEA_AUTH="0000000000000000000000000000000000000000"
REGISTRY_2_USER=
REGISTRY_2_DOMAIN=
REGISTRY_2_GITEA_AUTH=
# And so on...
# And then you set it, example:
export TARGET_REGISTRY_USER=$REGISTRY_1_USER
export TARGET_REGISTRY_DOMAIN=$REGISTRY_1_DOMAIN
export GITEA_AUTH_TOKEN=$REGISTRY_1_GITEA_AUTH

View file

@ -9,9 +9,14 @@ The guide to installing and configuring NPM and Yarn V3 follows.
## Short `npm` solution ## Short `npm` solution
```bash ```bash
# Replace T-Hax with tornadocash if the packages (in future) are under the org # Add into your .npmrc
# This should be updated manually though @tornado:registry=https://git.tornado.ws/api/packages/tornado-packages/npm/
# For any package add into your .npmrc ```
or
```bash
# Add into your .npmrc
@tornado:registry=https://development.tornadocash.community/api/packages/T-Hax/npm/ @tornado:registry=https://development.tornadocash.community/api/packages/T-Hax/npm/
``` ```

13
TLDR.md
View file

@ -1,9 +1,14 @@
repeating the short npm solution repeating the short npm solution
```yaml ```bash
# For any package add into your .npmrc # Add into your .npmrc
# Replace T-Hax with tornadocash if the packages (in future) are under the org @tornado:registry=https://git.tornado.ws/api/packages/tornado-packages/npm/
# This should be updated manually though ```
or
```bash
# Add into your .npmrc
@tornado:registry=https://development.tornadocash.community/api/packages/T-Hax/npm/ @tornado:registry=https://development.tornadocash.community/api/packages/T-Hax/npm/
``` ```

View file

@ -1,21 +1,18 @@
# So basically, we want to selectively download packages from the Gitea repository but still allow the # So basically, we want to selectively download packages from the Gitea repository but still allow the
# main repositories, so we are going to have to scope our packages properly. # main repositories, so we are going to have to scope our packages properly.
npmScopes: npmScopes:
# @tornado, the scope by which the following registries are selected
tornado: tornado:
# The @tornado scope can just be set to the right registry by editing the "T-Hax" here. # Since our repos are across multiple registries we select them via the .env we `source`.
# I could even make it an env var but it seems too much, env is better for secrets. # Check .env.example
npmPublishRegistry: "https://development.tornadocash.community/api/packages/T-Hax/npm/" npmRegistryServer: https://${TARGET_REGISTRY_DOMAIN}/api/packages/${TARGET_REGISTRY_USER}/npm/
npmRegistryServer: "https://development.tornadocash.community/api/packages/T-Hax/npm/" npmPublishRegistry: https://${TARGET_REGISTRY_DOMAIN}/api/packages/${TARGET_REGISTRY_USER}/npm/
npmAuthToken: ${GITEA_AUTH_TOKEN}
# The below can be EXPORTED via some env file which actually exports the variables though # If the following isn't set you won't have a node_modules folder, and will be using pnp instead
# Check the env.example, you will notice it's not a regular env # You might be used to a node_modules folder instead of a pnp or other linker type
# So split your env files up, since this is only for manual actions
# npmAuthToken: ${GITEA_AUTH_TOKEN}
# If the following isn't set you won't have a node_modules folder
# You might be used to a node_modules folder instead of a pnp or other folder type
# If you want to use the new linkers uncomment or change the following # If you want to use the new linkers uncomment or change the following
nodeLinker: "node-modules" nodeLinker: "node-modules"
# We disable telemetry for obvious reasons. # We disable telemetry for obvious reasons. enableTelemetry: false
enableTelemetry: false enableTelemetry: false