Skip to content

Commit

Permalink
Merge branch 'develop' into pdfjs-update
Browse files Browse the repository at this point in the history
  • Loading branch information
panaC committed Nov 26, 2024
2 parents 62e6240 + b643725 commit 00cfd2e
Show file tree
Hide file tree
Showing 12 changed files with 2,181 additions and 3,423 deletions.
6 changes: 6 additions & 0 deletions .flox/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
run/
cache/
lib/
log/
NPM_PREFIX/
NPM_CACHE/
4 changes: 4 additions & 0 deletions .flox/env.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"name": "thorium-reader",
"version": 1
}
159 changes: 159 additions & 0 deletions .flox/env/manifest.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
{
"lockfile-version": 1,
"manifest": {
"version": 1,
"install": {
"nodejs_22": {
"pkg-path": "nodejs_22"
}
},
"vars": {
"CLICOLOR": "1",
"FLOX_DISABLE_METRICS": "true"
},
"hook": {
"on-activate": "echo \"##################################################\";\necho \"########## FLOX ACTIVATE...\";\n\nPWD=$(pwd);\necho \"-----> PWD: ${PWD}\";\n\n#_FLOX_ENV_LOG_DIR\nFLOX_ENV_DIR=\"${FLOX_ENV_CACHE}/..\"\necho \"-----> FLOX_ENV_DIR: ${FLOX_ENV_DIR}\";\n\necho \"=====> NODE VERSION: $(node --version)\";\nWHICH_NODE=$(which node);\necho \".....> NODE WHICH: ${WHICH_NODE}\";\nls -alshF --color=auto \"${WHICH_NODE}\";\n\necho \"=====> NPM VERSION (init): $(npm --version)\";\nWHICH_NPM=$(which npm);\necho \".....> NPM WHICH: ${WHICH_NPM}\";\nls -alshF --color=auto \"${WHICH_NPM}\";\n\necho \"-----> NPM CONFIG PREFIX (init): $(npm config get prefix)\";\necho \"-----> NPM_CONFIG_PREFIX (init): ${NPM_CONFIG_PREFIX}\";\n\necho \"-----> NPM CONFIG CACHE (init): $(npm config get cache)\"\necho \"-----> NPM_CONFIG_CACHE (init): ${NPM_CONFIG_CACHE}\";\n\n# envName=\"${_FLOX_ACTIVE_ENVIRONMENTS##:*}\";\n#echo \"${envName}\";\n#export NPM_CONFIG_PREFIX=\"/tmp/${envName}-npm\";\n\nexport NPM_CONFIG_PREFIX=\"${FLOX_ENV_DIR}/NPM_PREFIX\";\necho \"-----> NPM CONFIG PREFIX: $(npm config get prefix)\";\necho \"-----> NPM_CONFIG_PREFIX: ${NPM_CONFIG_PREFIX}\";\n#### rm -rf \"$NPM_CONFIG_PREFIX\";\nmkdir -p \"$NPM_CONFIG_PREFIX\";\nls -alshF --color=auto \"$NPM_CONFIG_PREFIX\";\nls -alshF --color=auto \"$NPM_CONFIG_PREFIX/bin\";\nls -alshF --color=auto \"$NPM_CONFIG_PREFIX/lib\";\nls -alshF --color=auto \"$NPM_CONFIG_PREFIX/lib/node_modules\";\n\nexport NPM_CONFIG_CACHE=\"${FLOX_ENV_DIR}/NPM_CACHE\";\necho \"-----> NPM CONFIG CACHE: $(npm config get cache)\"\necho \"-----> NPM_CONFIG_CACHE: ${NPM_CONFIG_CACHE}\";\n#### rm -rf \"$NPM_CONFIG_CACHE\";\nmkdir -p \"$NPM_CONFIG_CACHE\";\nls -alshF --color=auto \"$NPM_CONFIG_CACHE\";\n\necho \"-----> NODE_PATH (init): ${NODE_PATH}\";\nexport NODE_PATH=\"$NPM_CONFIG_PREFIX/lib/node_modules${NODE_PATH:+:$NODE_PATH}\";\necho \"-----> NODE_PATH: ${NODE_PATH}\";\n\nexport PATH=\"$NPM_CONFIG_PREFIX/bin:$PATH\";\n\nnpm install -g npm\nnpm install -g npm-check-updates\nnpm install -g @electron/asar\n"
},
"profile": {
"common": "echo \"##################################################\";\necho \"########## FLOX PROFILE COMMON (${SHELL})...\";\n\nPWD=$(pwd);\necho \"-----> PWD: ${PWD}\";\n\necho \"=====> NODE VERSION: $(node --version)\";\nWHICH_NODE=$(which node);\necho \".....> NODE WHICH: ${WHICH_NODE}\";\nls -alshF --color=auto \"${WHICH_NODE}\";\n\necho \"=====> NPM VERSION: $(npm --version)\";\nWHICH_NPM=$(which npm);\necho \".....> NPM WHICH: ${WHICH_NPM}\";\nls -alshF --color=auto \"${WHICH_NPM}\";\n\necho \"-----> NPM CONFIG PREFIX: $(npm config get prefix)\";\necho \"-----> NPM_CONFIG_PREFIX: ${NPM_CONFIG_PREFIX}\";\n\necho \"-----> NPM CONFIG CACHE: $(npm config get cache)\"\necho \"-----> NPM_CONFIG_CACHE: ${NPM_CONFIG_CACHE}\";\n\necho \"=====> NCU VERSION: $(ncu --version)\";\nWHICH_NCU=$(which ncu);\necho \".....> NCU WHICH: ${WHICH_NCU}\";\nls -alshF --color=auto \"${WHICH_NCU}\";\n\necho \"=====> ASAR VERSION: $(asar --version)\";\nWHICH_ASAR=$(which asar);\necho \".....> ASAR WHICH: ${WHICH_ASAR}\";\nls -alshF --color=auto \"${WHICH_ASAR}\";\n\necho \"=====> GIT VERSION: $(git --version)\";\nWHICH_GIT=$(which git);\necho \".....> GIT WHICH: ${WHICH_GIT}\";\nls -alshF --color=auto \"${WHICH_GIT}\";\n\nENV=$(env);\necho \"-----> ENV: ${ENV}\";\necho \"||||||||||||||||||||||||||\";\n\necho \"-----> APPLEID: ${APPLEID}\";\necho \"-----> APPLEIDTEAM: ${APPLEIDTEAM}\";\necho \"-----> APPLEIDPASS: ${APPLEIDPASS}\";\necho \"-----> SKIP_NOTARIZE: ${SKIP_NOTARIZE}\";\necho \"-----> CSC_NAME: ${CSC_NAME}\";\n\necho \"-----> DEBUG: ${DEBUG}\";\n\necho \"-----> USER: ${USER}\";\necho \"-----> USERNAME: ${USERNAME}\";\n\necho \"-----> NODE_ENV: ${NODE_ENV}\";\n\necho \"-----> THORIUM_OPDS_CATALOGS_URL: ${THORIUM_OPDS_CATALOGS_URL}\";\necho \"-----> THORIUM_OPEN_DEVTOOLS: ${THORIUM_OPEN_DEVTOOLS}\";\necho \"-----> LCP_SKIP_LSD: ${LCP_SKIP_LSD}\";\necho \"-----> SKIP_CHECK_TYPESCRIPT: ${SKIP_CHECK_TYPESCRIPT}\";\necho \"-----> USE_LEGACY_TYPESCRIPT_LOADER: ${USE_LEGACY_TYPESCRIPT_LOADER}\";\necho \"-----> THORIUM_TELEMETRY_SECRET: ${THORIUM_TELEMETRY_SECRET}\";\necho \"-----> THORIUM_TELEMETRY_URL: ${THORIUM_TELEMETRY_URL}\";\necho \"-----> PACKAGING: ${PACKAGING}\";\necho \"-----> GITHUB_TOKEN_RELEASE_PUBLISH: ${GITHUB_TOKEN_RELEASE_PUBLISH}\";\necho \"-----> VSCODE_LAUNCH: ${VSCODE_LAUNCH}\";\necho \"-----> PORT_APP: ${PORT_APP}\";\necho \"-----> PORT_READER: ${PORT_READER}\";\necho \"-----> PORT_PDF_WEBVIEW: ${PORT_PDF_WEBVIEW}\";\n\ngit branch\ngit status\n"
},
"options": {
"systems": [
"aarch64-darwin",
"aarch64-linux",
"x86_64-darwin",
"x86_64-linux"
],
"allow": {
"licenses": []
},
"semver": {}
}
},
"packages": [
{
"attr_path": "nodejs_22",
"broken": false,
"derivation": "/nix/store/ghzk28xlqjdjqyicfng40r4hyglr7nxm-nodejs-22.10.0.drv",
"description": "Event-driven I/O framework for the V8 JavaScript engine",
"install_id": "nodejs_22",
"license": "MIT",
"locked_url": "https://github.com/flox/nixpkgs?rev=23e89b7da85c3640bbc2173fe04f4bd114342367",
"name": "nodejs-22.10.0",
"pname": "nodejs_22",
"rev": "23e89b7da85c3640bbc2173fe04f4bd114342367",
"rev_count": 710087,
"rev_date": "2024-11-19T11:04:08Z",
"scrape_date": "2024-11-21T04:00:36Z",
"stabilities": [
"staging",
"unstable"
],
"unfree": false,
"version": "nodejs-22.10.0",
"outputs_to_install": [
"out"
],
"outputs": {
"libv8": "/nix/store/6rgrpzdbylr432xa1r4mi9wc5i2bgvw0-nodejs-22.10.0-libv8",
"out": "/nix/store/3r50cvcf5d7fahnkx4nkr2nk3h377h4s-nodejs-22.10.0"
},
"system": "aarch64-darwin",
"group": "toplevel",
"priority": 5
},
{
"attr_path": "nodejs_22",
"broken": false,
"derivation": "/nix/store/59bhgby39hvvss9a3dmzz3pa4mch6fqq-nodejs-22.10.0.drv",
"description": "Event-driven I/O framework for the V8 JavaScript engine",
"install_id": "nodejs_22",
"license": "MIT",
"locked_url": "https://github.com/flox/nixpkgs?rev=23e89b7da85c3640bbc2173fe04f4bd114342367",
"name": "nodejs-22.10.0",
"pname": "nodejs_22",
"rev": "23e89b7da85c3640bbc2173fe04f4bd114342367",
"rev_count": 710087,
"rev_date": "2024-11-19T11:04:08Z",
"scrape_date": "2024-11-21T04:00:36Z",
"stabilities": [
"staging",
"unstable"
],
"unfree": false,
"version": "nodejs-22.10.0",
"outputs_to_install": [
"out"
],
"outputs": {
"libv8": "/nix/store/3df03syl7rz631377l76mjvbizrnl26c-nodejs-22.10.0-libv8",
"out": "/nix/store/fxx7iihgsj0ysdvz09wsazi9ih6g1ss8-nodejs-22.10.0"
},
"system": "aarch64-linux",
"group": "toplevel",
"priority": 5
},
{
"attr_path": "nodejs_22",
"broken": false,
"derivation": "/nix/store/8qc98kwvbnakhirfb6w8x38qnwdi25p8-nodejs-22.10.0.drv",
"description": "Event-driven I/O framework for the V8 JavaScript engine",
"install_id": "nodejs_22",
"license": "MIT",
"locked_url": "https://github.com/flox/nixpkgs?rev=23e89b7da85c3640bbc2173fe04f4bd114342367",
"name": "nodejs-22.10.0",
"pname": "nodejs_22",
"rev": "23e89b7da85c3640bbc2173fe04f4bd114342367",
"rev_count": 710087,
"rev_date": "2024-11-19T11:04:08Z",
"scrape_date": "2024-11-21T04:00:36Z",
"stabilities": [
"staging",
"unstable"
],
"unfree": false,
"version": "nodejs-22.10.0",
"outputs_to_install": [
"out"
],
"outputs": {
"libv8": "/nix/store/qs45lfyf8rzgh1ghb1g2m9pa50njwxcx-nodejs-22.10.0-libv8",
"out": "/nix/store/vh70nd2rjh0nzfqsn4iwibz1s07f4fhv-nodejs-22.10.0"
},
"system": "x86_64-darwin",
"group": "toplevel",
"priority": 5
},
{
"attr_path": "nodejs_22",
"broken": false,
"derivation": "/nix/store/wxa0y02xqvkr220dgbgjnncyqp4pr4br-nodejs-22.10.0.drv",
"description": "Event-driven I/O framework for the V8 JavaScript engine",
"install_id": "nodejs_22",
"license": "MIT",
"locked_url": "https://github.com/flox/nixpkgs?rev=23e89b7da85c3640bbc2173fe04f4bd114342367",
"name": "nodejs-22.10.0",
"pname": "nodejs_22",
"rev": "23e89b7da85c3640bbc2173fe04f4bd114342367",
"rev_count": 710087,
"rev_date": "2024-11-19T11:04:08Z",
"scrape_date": "2024-11-21T04:00:36Z",
"stabilities": [
"staging",
"unstable"
],
"unfree": false,
"version": "nodejs-22.10.0",
"outputs_to_install": [
"out"
],
"outputs": {
"libv8": "/nix/store/j0nfkz29q3iigzl6ly1a75bivd1bsqc3-nodejs-22.10.0-libv8",
"out": "/nix/store/0xvgzkl74v6jrh79ibh7ss770dh4hb69-nodejs-22.10.0"
},
"system": "x86_64-linux",
"group": "toplevel",
"priority": 5
}
]
}
191 changes: 191 additions & 0 deletions .flox/env/manifest.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,191 @@
#
# This is a Flox environment manifest.
# Visit flox.dev/docs/concepts/manifest/
# or see flox-edit(1), manifest.toml(5) for more information.
#
# Flox manifest version managed by Flox CLI
version = 1

# List packages you wish to install in your environment inside
# the `[install]` section.
[install]
nodejs_22.pkg-path = "nodejs_22"
# hello.pkg-path = "hello"
# nodejs = { version = "^20.15.1", pkg-path = "nodejs" }

# Set environment variables in the `[vars]` section. These variables may not
# reference one another, and are added to the environment without first
# expanding them. They are available for use in the `[profile]` and `[hook]`
# scripts.
[vars]
# message = "Howdy"
FLOX_DISABLE_METRICS="true"
CLICOLOR="1"

# The `hook.on-activate` script is run by the *bash* shell immediately upon
# activating an environment, and will not be invoked if Flox detects that the
# environment has previously been activated. Variables set by the script will
# be inherited by `[profile]` scripts defined below. Note that any stdout
# generated by the script will be redirected to stderr.
[hook]
on-activate = '''
echo "##################################################";
echo "########## FLOX ACTIVATE...";
PWD=$(pwd);
echo "-----> PWD: ${PWD}";
#_FLOX_ENV_LOG_DIR
FLOX_ENV_DIR="${FLOX_ENV_CACHE}/.."
echo "-----> FLOX_ENV_DIR: ${FLOX_ENV_DIR}";
echo "=====> NODE VERSION: $(node --version)";
WHICH_NODE=$(which node);
echo ".....> NODE WHICH: ${WHICH_NODE}";
ls -alshF --color=auto "${WHICH_NODE}";
echo "=====> NPM VERSION (init): $(npm --version)";
WHICH_NPM=$(which npm);
echo ".....> NPM WHICH: ${WHICH_NPM}";
ls -alshF --color=auto "${WHICH_NPM}";
echo "-----> NPM CONFIG PREFIX (init): $(npm config get prefix)";
echo "-----> NPM_CONFIG_PREFIX (init): ${NPM_CONFIG_PREFIX}";
echo "-----> NPM CONFIG CACHE (init): $(npm config get cache)"
echo "-----> NPM_CONFIG_CACHE (init): ${NPM_CONFIG_CACHE}";
# envName="${_FLOX_ACTIVE_ENVIRONMENTS##:*}";
#echo "${envName}";
#export NPM_CONFIG_PREFIX="/tmp/${envName}-npm";
export NPM_CONFIG_PREFIX="${FLOX_ENV_DIR}/NPM_PREFIX";
echo "-----> NPM CONFIG PREFIX: $(npm config get prefix)";
echo "-----> NPM_CONFIG_PREFIX: ${NPM_CONFIG_PREFIX}";
#### rm -rf "$NPM_CONFIG_PREFIX";
mkdir -p "$NPM_CONFIG_PREFIX";
ls -alshF --color=auto "$NPM_CONFIG_PREFIX";
ls -alshF --color=auto "$NPM_CONFIG_PREFIX/bin";
ls -alshF --color=auto "$NPM_CONFIG_PREFIX/lib";
ls -alshF --color=auto "$NPM_CONFIG_PREFIX/lib/node_modules";
export NPM_CONFIG_CACHE="${FLOX_ENV_DIR}/NPM_CACHE";
echo "-----> NPM CONFIG CACHE: $(npm config get cache)"
echo "-----> NPM_CONFIG_CACHE: ${NPM_CONFIG_CACHE}";
#### rm -rf "$NPM_CONFIG_CACHE";
mkdir -p "$NPM_CONFIG_CACHE";
ls -alshF --color=auto "$NPM_CONFIG_CACHE";
echo "-----> NODE_PATH (init): ${NODE_PATH}";
export NODE_PATH="$NPM_CONFIG_PREFIX/lib/node_modules${NODE_PATH:+:$NODE_PATH}";
echo "-----> NODE_PATH: ${NODE_PATH}";
export PATH="$NPM_CONFIG_PREFIX/bin:$PATH";
npm install -g npm
npm install -g npm-check-updates
npm install -g @electron/asar
'''
# on-activate = '''
# # Set variables, create files and directories
# venv_dir="$(mktemp -d)"
# export venv_dir
#
# # Perform initialization steps, e.g. create a python venv
# python -m venv "$venv_dir"
# '''

# Scripts defined in the `[profile]` section are *sourced* by *your shell* and
# inherit environment variables set in the `[vars]` section and by `[hook]` scripts.
# The `profile.common` script is sourced by all shells and special care should be
# taken to ensure compatibility with all shells, after which exactly one of
# `profile.{bash,fish,tcsh,zsh}` is sourced by the corresponding shell.
[profile]
# common = '''
# echo "it's gettin' flox in here"
# '''
common = '''
echo "##################################################";
echo "########## FLOX PROFILE COMMON (${SHELL})...";
PWD=$(pwd);
echo "-----> PWD: ${PWD}";
echo "=====> NODE VERSION: $(node --version)";
WHICH_NODE=$(which node);
echo ".....> NODE WHICH: ${WHICH_NODE}";
ls -alshF --color=auto "${WHICH_NODE}";
echo "=====> NPM VERSION: $(npm --version)";
WHICH_NPM=$(which npm);
echo ".....> NPM WHICH: ${WHICH_NPM}";
ls -alshF --color=auto "${WHICH_NPM}";
echo "-----> NPM CONFIG PREFIX: $(npm config get prefix)";
echo "-----> NPM_CONFIG_PREFIX: ${NPM_CONFIG_PREFIX}";
echo "-----> NPM CONFIG CACHE: $(npm config get cache)"
echo "-----> NPM_CONFIG_CACHE: ${NPM_CONFIG_CACHE}";
echo "=====> NCU VERSION: $(ncu --version)";
WHICH_NCU=$(which ncu);
echo ".....> NCU WHICH: ${WHICH_NCU}";
ls -alshF --color=auto "${WHICH_NCU}";
echo "=====> ASAR VERSION: $(asar --version)";
WHICH_ASAR=$(which asar);
echo ".....> ASAR WHICH: ${WHICH_ASAR}";
ls -alshF --color=auto "${WHICH_ASAR}";
echo "=====> GIT VERSION: $(git --version)";
WHICH_GIT=$(which git);
echo ".....> GIT WHICH: ${WHICH_GIT}";
ls -alshF --color=auto "${WHICH_GIT}";
ENV=$(env);
echo "-----> ENV: ${ENV}";
echo "||||||||||||||||||||||||||";
echo "-----> APPLEID: ${APPLEID}";
echo "-----> APPLEIDTEAM: ${APPLEIDTEAM}";
echo "-----> APPLEIDPASS: ${APPLEIDPASS}";
echo "-----> SKIP_NOTARIZE: ${SKIP_NOTARIZE}";
echo "-----> CSC_NAME: ${CSC_NAME}";
echo "-----> DEBUG: ${DEBUG}";
echo "-----> USER: ${USER}";
echo "-----> USERNAME: ${USERNAME}";
echo "-----> NODE_ENV: ${NODE_ENV}";
echo "-----> THORIUM_OPDS_CATALOGS_URL: ${THORIUM_OPDS_CATALOGS_URL}";
echo "-----> THORIUM_OPEN_DEVTOOLS: ${THORIUM_OPEN_DEVTOOLS}";
echo "-----> LCP_SKIP_LSD: ${LCP_SKIP_LSD}";
echo "-----> SKIP_CHECK_TYPESCRIPT: ${SKIP_CHECK_TYPESCRIPT}";
echo "-----> USE_LEGACY_TYPESCRIPT_LOADER: ${USE_LEGACY_TYPESCRIPT_LOADER}";
echo "-----> THORIUM_TELEMETRY_SECRET: ${THORIUM_TELEMETRY_SECRET}";
echo "-----> THORIUM_TELEMETRY_URL: ${THORIUM_TELEMETRY_URL}";
echo "-----> PACKAGING: ${PACKAGING}";
echo "-----> GITHUB_TOKEN_RELEASE_PUBLISH: ${GITHUB_TOKEN_RELEASE_PUBLISH}";
echo "-----> VSCODE_LAUNCH: ${VSCODE_LAUNCH}";
echo "-----> PORT_APP: ${PORT_APP}";
echo "-----> PORT_READER: ${PORT_READER}";
echo "-----> PORT_PDF_WEBVIEW: ${PORT_PDF_WEBVIEW}";
git branch
git status
'''

# The `[services]` section of the manifest allows you to define services.
# Services defined here use the packages provided by the `[install]` section
# and any variables you've defined in the `[vars]` section or `hook.on-activate` script.
[services]
# postgres.command = "postgres --config-file=pg.conf"

# Additional options can be set in the `[options]` section. Refer to
# manifest.toml(5) for a list of available options.
[options]
systems = ["aarch64-darwin", "aarch64-linux", "x86_64-darwin", "x86_64-linux"]
# Uncomment to disable CUDA detection.
# cuda-detection = false
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,10 @@ node_modules
.DS_Store
lcp.node
external-assets/*
.zed
.flox/cache
.flox/log
.flox/run
.flox/lib
.flox/NPM_PREFIX
.flox/NPM_CACHE
Loading

0 comments on commit 00cfd2e

Please sign in to comment.