'Generic Commit'
This commit is contained in:
parent
3ab8fe87d3
commit
b47d4de45e
@ -20,7 +20,7 @@ Install any tool from the getpkg registry:
|
||||
|
||||
```bash
|
||||
# Install a tool
|
||||
getpkg install ripgrep
|
||||
getpkg install whatsdirty
|
||||
```
|
||||
|
||||
### Managing Installed Tools
|
||||
@ -33,7 +33,7 @@ getpkg help
|
||||
getpkg update
|
||||
|
||||
# Uninstall a tool
|
||||
getpkg uninstall ripgrep
|
||||
getpkg uninstall whatsdirty
|
||||
|
||||
# Check getpkg version
|
||||
getpkg version
|
||||
@ -100,7 +100,7 @@ Tools are automatically downloaded for your architecture, with fallback to unive
|
||||
|
||||
```bash
|
||||
# Install development tools
|
||||
getpkg ripgrep # Fast grep alternative
|
||||
getpkg whatsdirty # Fast grep alternative
|
||||
getpkg fd # Fast find alternative
|
||||
getpkg bat # Cat with syntax highlighting
|
||||
|
||||
|
@ -815,7 +815,7 @@ void show_help() {
|
||||
std::cout << " help Show this help message" << std::endl;
|
||||
std::cout << std::endl;
|
||||
std::cout << "EXAMPLES:" << std::endl;
|
||||
std::cout << " getpkg install ripgrep Install ripgrep tool" << std::endl;
|
||||
std::cout << " getpkg install whatsdirty Install whatsdirty tool" << std::endl;
|
||||
std::cout << " getpkg install myapp Install myapp" << std::endl;
|
||||
std::cout << " getpkg publish myapp:x86_64 ./build Publish architecture-specific build" << std::endl;
|
||||
std::cout << " getpkg publish myapp ./build Publish universal build" << std::endl;
|
||||
|
@ -2,7 +2,7 @@
|
||||
set -euo pipefail
|
||||
|
||||
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
|
||||
WHATSDIRTY_SCRIPT="$SCRIPT_DIR/whatsdirty.sh"
|
||||
WHATSDIRTY_SCRIPT="$SCRIPT_DIR/whatsdirty"
|
||||
CONFIG_FILE="$HOME/.config/whatsdirty.conf"
|
||||
BACKUP_FILE=""
|
||||
TEST_PASSED=true
|
||||
@ -25,7 +25,12 @@ print_test() {
|
||||
}
|
||||
|
||||
# Function to cleanup and restore
|
||||
CLEANED=false
|
||||
cleanup() {
|
||||
if [ "$CLEANED" = true ]; then
|
||||
return
|
||||
fi
|
||||
CLEANED=true
|
||||
if [ -n "$BACKUP_FILE" ] && [ -f "$BACKUP_FILE" ]; then
|
||||
cp "$BACKUP_FILE" "$CONFIG_FILE"
|
||||
rm -f "$BACKUP_FILE"
|
||||
@ -38,7 +43,7 @@ cleanup() {
|
||||
# Set up trap to restore config on exit
|
||||
trap cleanup EXIT
|
||||
|
||||
echo "Testing whatsdirty.sh configuration behavior..."
|
||||
echo "Testing whatsdirty configuration behavior..."
|
||||
echo "Working directory: $(pwd)"
|
||||
echo "Script path: $WHATSDIRTY_SCRIPT"
|
||||
echo "Config file: $CONFIG_FILE"
|
||||
@ -148,6 +153,8 @@ else
|
||||
echo " Got: $OUTPUT"
|
||||
fi
|
||||
|
||||
cleanup
|
||||
|
||||
# Summary
|
||||
echo
|
||||
if [ "$TEST_PASSED" = true ]; then
|
||||
@ -157,3 +164,4 @@ else
|
||||
echo -e "${RED}Some tests failed!${NC}"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user