-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* chore: init command * chore: ci * chore: ci * chore different releases * feat: queue manager * chore: add lockfile status tests * chore: tests and fixes * chore: opeanpi * chore: legacy commands * chore: new scroll related commands * fix: htop example
- Loading branch information
Showing
37 changed files
with
1,194 additions
and
586 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,19 @@ | ||
#!/bin/bash | ||
|
||
#check if first argument is there, set CHANNEL to it, otherwise default to latest | ||
if [ -z "$1" ]; then | ||
CHANNEL="$CHANNEL/download" | ||
if [ -z "$CHANNEL" ]; then | ||
URL_PATH="latest/download" | ||
else | ||
CHANNEL=download/$1 | ||
URL_PATH=download/$CHANNEL | ||
fi | ||
|
||
wget -O /app/resources/druid https://github.com/highcard-dev/druid-cli/releases/$CHANNEL/druid | ||
wget -O /app/resources/druid_rcon https://github.com/highcard-dev/druid-cli/releases/$CHANNEL/druid_rcon | ||
wget -O /app/resources/druid_rcon_web https://github.com/highcard-dev/druid-cli/releases/$CHANNEL/druid_rcon_web | ||
wget -O /app/resources/entrypoint.sh https://github.com/highcard-dev/druid-cli/releases/$CHANNEL/entrypoint.sh | ||
wget -O /app/resources/druid https://github.com/highcard-dev/druid-cli/releases/$URL_PATH/druid | ||
wget -O /app/resources/druid_rcon https://github.com/highcard-dev/druid-cli/releases/$URL_PATH/druid_rcon | ||
wget -O /app/resources/druid_rcon_web https://github.com/highcard-dev/druid-cli/releases/$URL_PATH/druid_rcon_web | ||
wget -O /app/resources/entrypoint.sh https://github.com/highcard-dev/druid-cli/releases/$URL_PATH/entrypoint.sh | ||
chmod +x /app/resources/druid /app/resources/druid_rcon /app/resources/druid_rcon_web | ||
|
||
# Modify the PATH variable to prioritize /app/resources | ||
export PATH=/app/resources:$PATH | ||
|
||
bash /app/resources/entrypoint.sh | ||
|
||
#https://github.com/highcard-dev/druid-cli/releases/download/0.1.8-prerelease3/druid | ||
bash /app/resources/entrypoint.sh $@ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package cmd | ||
|
||
import ( | ||
"github.com/spf13/cobra" | ||
) | ||
|
||
// scrollCmd represents the command for scrolling | ||
var ScrollCmd = &cobra.Command{ | ||
Use: "scroll", | ||
Short: "Commands related to the scroll file", | ||
Long: `Commands related to the scroll file`, | ||
Run: func(cmd *cobra.Command, args []string) { | ||
cmd.Usage() | ||
}, | ||
} | ||
|
||
func init() { | ||
ScrollCmd.AddCommand(ScrollValidateCmd) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package cmd | ||
|
||
import ( | ||
"fmt" | ||
|
||
"github.com/highcard-dev/daemon/internal/core/domain" | ||
"github.com/spf13/cobra" | ||
) | ||
|
||
var ScrollValidateCmd = &cobra.Command{ | ||
Use: "validate", | ||
Short: "Validates the scroll file", | ||
Long: `This command validates the scroll file to ensure it meets the required criteria.`, | ||
Args: cobra.MaximumNArgs(1), | ||
RunE: func(cmd *cobra.Command, args []string) error { | ||
scrollDir := cwd | ||
if len(args) > 0 { | ||
scrollDir = args[0] | ||
} | ||
|
||
scroll, err := domain.NewScroll(scrollDir) | ||
|
||
if err != nil { | ||
return fmt.Errorf("failed to load scroll: %w", err) | ||
} | ||
|
||
if err := scroll.Validate(); err != nil { | ||
return fmt.Errorf("failed to validate scroll: %w", err) | ||
} | ||
|
||
fmt.Println("Scroll validated successfully.") | ||
return nil | ||
}, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.