Skip to content

Commit

Permalink
Remove unused options.
Browse files Browse the repository at this point in the history
  • Loading branch information
danfuzz committed Sep 28, 2023
1 parent 2b12eb5 commit 80e4bf3
Showing 1 changed file with 1 addition and 30 deletions.
31 changes: 1 addition & 30 deletions scripts/lib/lactoserv/build-js-project
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,6 @@ define-usage $'
--allow-platform-specific-files
If specified, the build does *not* check to see if any platform-specific
files ended up in the built output.
--clean
Do a clean build for the project. This will attempt to clean out *just*
the stuff for the named project.
--clean-all
Do a completely clean build. This will erase the entire built-output
directory.
--out=<dir>
Directory where built output goes. Defaults to `out` directly under the
main product directory.
Expand All @@ -37,12 +31,6 @@ opt-action --call='{ usage; exit }' help/h
# Allow the build to be platform-specific?
opt-toggle --var=platformSpecific allow-platform-specific-files

# Clean project build?
opt-toggle --var=doCleanProject clean

# Completely clean build?
opt-toggle --var=doCleanAll clean-all

# Built output directory.
opt-value --var=outDir out

Expand Down Expand Up @@ -325,17 +313,6 @@ function remove-dead-local-modules {
fi
}

# Sets up the output directory.
function set-up-out-dir {
local extraOpts=()
if (( doCleanAll )); then
extraOpts=(--remove)
fi

lib buildy out-dir --quiet \
--out="${outDir}" --create --print "${extraOpts[@]}"
}

# Checks a `node_modules` directory (or similar) for "suspect" files, given a
# desire to have a platform-agnostic build.
function suspect-file-check {
Expand Down Expand Up @@ -377,16 +354,10 @@ function suspect-file-check {
progress-msg "Building JS project ${projectName}..."

srcDir="$(base-dir)/src"
outDir="$(set-up-out-dir)"
outDir="$(lib buildy out-dir --out="${outDir}" --create --print --quiet)"

outProjectDir="${outDir}/${projectName}"

if (( doCleanProject )); then
progress-msg 'Removing project-specific output directory...'
rm -rf "${outProjectDir}" \
|| exit "$?"
fi

if [[ ! -d ${outProjectDir} ]]; then
progress-msg 'Creating project-specific output directory...'
mkdir -p "${outProjectDir}" \
Expand Down

0 comments on commit 80e4bf3

Please sign in to comment.