@@ -6,21 +6,21 @@ export MSYS_NO_PATHCONV=1 # for Git Bash on Windows
66
77SCRIPT_DIR=" $( cd " $( dirname " ${BASH_SOURCE[0]} " ) " &&  pwd) " 
88ROOT_DIR=" $SCRIPT_DIR /../.." 
9- DEPENDENCIES_DOCKERFILE=" $SCRIPT_DIR /dependencies.dockerfile " 
9+ DEPENDENCIES_DOCKERFILE=" $SCRIPT_DIR /dependencies.Dockerfile " 
1010
1111#  Parse command line arguments
12- RELATIVE_ONLY =false
13- MODIFIED_FILES =" " 
12+ LOCAL_LINKS_ONLY =false
13+ TARGET =" " 
1414
1515while  [[ $#  -gt  0 ]];  do 
1616    case  $1  in 
17-         --relative -only)
18-             RELATIVE_ONLY =true
17+         --local-links -only)
18+             LOCAL_LINKS_ONLY =true
1919            shift 
2020            ;;
2121        * )
2222            #  Treat any other arguments as file paths
23-             MODIFIED_FILES =" $MODIFIED_FILES   $1 " 
23+             TARGET =" $TARGET   $1 " 
2424            shift 
2525            ;;
2626    esac 
2929#  Extract lychee version from dependencies.dockerfile
3030LYCHEE_VERSION=$( grep " FROM lycheeverse/lychee:" " $DEPENDENCIES_DOCKERFILE " |  sed ' s/.*FROM lycheeverse\/lychee:\([^ ]*\).*/\1/' ) 
3131
32- #  Determine target files/directories and config file
33- TARGET=" ." 
34- LYCHEE_CONFIG=" .github/scripts/.lychee.toml" 
35- 
36- if  [[ " $RELATIVE_ONLY " ==  " true" ;  then 
37-     LYCHEE_CONFIG=" .github/scripts/.lychee-relative.toml" 
38- fi 
39- 
40- if  [[ -n  " $MODIFIED_FILES " ;  then 
41-     TARGET=" $MODIFIED_FILES " 
32+ if  [[ -z  " $TARGET " ;  then 
33+     TARGET=" ." 
4234fi 
4335
4436#  Build the lychee command with optional GitHub token
45- CMD=" lycheeverse/lychee:$LYCHEE_VERSION  --verbose --config  $LYCHEE_CONFIG " 
37+ CMD=" lycheeverse/lychee:$LYCHEE_VERSION  --verbose --root-dir /data " 
4638
4739#  Add GitHub token if available
4840if  [[ -n  " $GITHUB_TOKEN " ;  then 
4941    CMD=" $CMD  --github-token $GITHUB_TOKEN " 
5042fi 
5143
44+ if  [[ " $LOCAL_LINKS_ONLY " ==  " true" ;  then 
45+     CMD=" $CMD  --scheme file --include-fragments" 
46+ else 
47+     CMD=" $CMD  --config .github/scripts/lychee-config.toml" 
48+ fi 
49+ 
5250CMD=" $CMD  $TARGET " 
5351
5452#  Determine if we should allocate a TTY
0 commit comments