changed app to use json config for pipeline steps

readme command line usage - to specify pipeline file name
readme updated to include reasoning behind the project

use native golang sqlite

RunScriptCommand named in functionMap
removed unused functions
removed unused functions
run script and pipeline example
renamed functions to drop the word script and add pipeline verb
This commit is contained in:
jon brookes 2025-07-09 13:19:43 +01:00 committed by jon brookes
parent bd7cee720a
commit 924954d0ff
49 changed files with 2059 additions and 101 deletions

29
config/customer.go Normal file
View file

@ -0,0 +1,29 @@
package config
import (
"encoding/json"
"fmt"
"os"
)
type CustomerConfig struct {
Project string `json:"project"`
CustomerDirectory string `json:"customer_directory"`
UIURL string `json:"ui_url"`
StaticURL string `json:"static_url"`
Port int `json:"port"`
}
func ReadCustomerConfig(path string) (CustomerConfig, error) {
data, err := os.ReadFile(path)
if err != nil {
return CustomerConfig{}, fmt.Errorf("failed to read file: %w", err)
}
var cust CustomerConfig
if err := json.Unmarshal(data, &cust); err != nil {
return CustomerConfig{}, fmt.Errorf("failed to unmarshal JSON: %w", err)
}
return cust, nil
}