summaryrefslogtreecommitdiff
path: root/init.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-08-21 14:40:41 -0500
committerJeff Carr <[email protected]>2025-08-21 14:40:41 -0500
commit6db458b2dfbc45b63db0d5a6b37515df33599e3a (patch)
tree978025ea49d5f2ddf49793a677d10bfa727ad9a4 /init.go
parentfd4b2aa6c9ff9d6c733bcbc98c9a0f5338a257be (diff)
hopefully works?
Diffstat (limited to 'init.go')
-rw-r--r--init.go16
1 files changed, 16 insertions, 0 deletions
diff --git a/init.go b/init.go
index 4d1c208..1470af5 100644
--- a/init.go
+++ b/init.go
@@ -150,6 +150,22 @@ func (f *Forge) InitPB() {
f.rillY = 20
}
+// set the URL for forge otherwise fallback to ENV or to forge.wit.com
+func (f *Forge) SetForgeURL(url string) {
+ if url == "" {
+ url = os.Getenv("FORGE_URL")
+ }
+ if url == "" {
+ url = "https://forge.wit.com/"
+ }
+ f.forgeURL = url
+ log.Info("Forge URL has been set to", f.forgeURL)
+}
+
+func (f *Forge) GetForgeURL() string {
+ return f.forgeURL
+}
+
func (f *Forge) InitMachine() {
if f.Config.Username == "" {
usr, _ := user.Current()