diff --git a/cmd b/cmd index 58a13d9..7cf2667 100755 --- a/cmd +++ b/cmd @@ -16,4 +16,6 @@ subcmd="$1" shift -exec "$DIR"/cmd.d/"$subcmd" "$@" +echo will run "$DIR"/framework/cmd.d/"$subcmd" "$@" + +exec "$DIR"/framework/cmd.d/"$subcmd" "$@" diff --git a/cmd.d/list b/framework/cmd.d/list similarity index 100% rename from cmd.d/list rename to framework/cmd.d/list diff --git a/framework/cmd.d/node b/framework/cmd.d/node new file mode 100755 index 0000000..dea36cd --- /dev/null +++ b/framework/cmd.d/node @@ -0,0 +1,7 @@ +#!/bin/bash + +set -eu + +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" + +"$DIR"/../shims/node "$@" diff --git a/cmd.d/pnpm b/framework/cmd.d/pnpm similarity index 69% rename from cmd.d/pnpm rename to framework/cmd.d/pnpm index 05bc6da..f31a0b7 100755 --- a/cmd.d/pnpm +++ b/framework/cmd.d/pnpm @@ -4,4 +4,4 @@ set -eu DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" -"$DIR"/../framework/shims/pnpm "$@" \ No newline at end of file +"$DIR"/../shims/pnpm "$@" diff --git a/cmd.d/sync b/framework/cmd.d/sync old mode 100644 new mode 100755 similarity index 77% rename from cmd.d/sync rename to framework/cmd.d/sync index 2cdbc53..6684a6a --- a/cmd.d/sync +++ b/framework/cmd.d/sync @@ -14,4 +14,8 @@ DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" -cd $DIR/../framework/node \ No newline at end of file +cd $DIR/../node + +$DIR/pnpm install + +echo we will download other files here later diff --git a/framework/shims/common b/framework/shims/common new file mode 100644 index 0000000..9244976 --- /dev/null +++ b/framework/shims/common @@ -0,0 +1,4 @@ +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +ROOT="$DIR/../../" + + diff --git a/framework/shims/node b/framework/shims/node index 083ab35..671020a 100755 --- a/framework/shims/node +++ b/framework/shims/node @@ -1,5 +1,7 @@ #!/bin/bash +# This file belongs to the framework. You are not expected to modify it. + set -eu export DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" diff --git a/framework/shims/npm b/framework/shims/npm new file mode 100755 index 0000000..d6b7e7a --- /dev/null +++ b/framework/shims/npm @@ -0,0 +1,15 @@ +#!/bin/bash + +set -eu + +DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" + +source "$DIR"/node.common + +cd $DIR/../.nodejs-config +echo in dir $(pwd) +npm "$@" + + + + diff --git a/framework/shims/pnpm b/framework/shims/pnpm index 3aa9376..33c4c8a 100755 --- a/framework/shims/pnpm +++ b/framework/shims/pnpm @@ -5,9 +5,8 @@ set -eu DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" source "$DIR"/node.common +source "$DIR"/common -# "$DIR"/../.nodejs-config/node_modules/.bin/pnpm "$@" - -echo pnpm file: "$DIR"/../shims/pnpm +cd $ROOT/framework/node exec "$DIR"/../binaries/pnpm "$@"