Added flags to ls

This commit is contained in:
Laukka 2025-01-11 15:05:19 +01:00
parent 4ed189affe
commit 45ba77c3fb

View File

@ -14,7 +14,7 @@ var flagsDictionary map[string]string = map[string]string{"a": "-a shows hidden
func Ls(in input_parser.Input, env *environment.Env, flags string) {
if flags == "help" || flags == "-help" {
fmt.Printf("Lists Sources in the current working directory")
fmt.Printf("Supported flags are")
fmt.Printf("Supported flags are:")
for i := 0; i < len(flagsArray); i++ {
fmt.Println(flagsArray[i] + flagsDictionary[flagsArray[i]])
} // this prints all flags and their description