Skip to content

Commit

Permalink
GPT-commit: Refactored README_TEMPLATE & modified fopen script logic
Browse files Browse the repository at this point in the history
Refactored logic in `README_TEMPLATE.md` for better readability and updated functionality for `fopen.sh` script to improve file opening efficiency.
  • Loading branch information
hwixley committed Feb 24, 2024
1 parent 4e7ac38 commit 029cc05
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/README_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Provides developers with the ability for optimising the execution of commonly pe

## Why It Was Made

I found myself executing the same commands repeatedly, finding navigation on the terminal for frequently accessed locations needlessly slow, and the task of pushing out new code via manually submitting a PR on my browser repetitive and time-wasting. I decided to start developing my own bash scripting library to help alleviate these issues, and realized the whole world of opportunity I had to help optimize my own daily workflows on the terminal. Due to my experience working simultaneously on Mac and Linux machines one of the key parts of the WYX-CLI project was to also allow the same code to run in different shells and operating systems.
I found myself executing the same commands repeatedly, finding navigation on the terminal for frequently accessed locations needlessly slow, and the task of pushing out new code via manually submitting a PR on my browser repetitive and time-wasting. I decided to start developing my own bash scripting library to help alleviate these issues, and realized the whole world of opportunity I had to help optimize my own daily workflows on the terminal. Due to my experience working simultaneously on Mac and Linux machines one of the key parts of the WYX-CLI project was to also allow the same code to run in different shells and operating systems.

<hr>

Expand Down
5 changes: 4 additions & 1 deletion src/commands/fopen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,11 @@ if wyxd.arggt "1"; then
mydir="${mydirs[$dir]/\~/${HOME}}"
sys.log.info "Opening $WYX_DIR..."
sys.util.openfile "$WYX_DIR"
elif [ -f "$dir" ]; then
sys.log.info "Opening file..."
sys.util.openfile "$dir"
else
sys.log.error "Directory alias does not exist"
sys.log.error "Invalid directory or file"
fi
else
sys.log.info "Opening current directory..."
Expand Down

0 comments on commit 029cc05

Please sign in to comment.