File tree Expand file tree Collapse file tree 12 files changed +542
-0
lines changed
Expand file tree Collapse file tree 12 files changed +542
-0
lines changed Original file line number Diff line number Diff line change 1+ @ echo off
2+ echo Building...
3+ go build -o .\bin\GoFileEncoder.exe .\src\
4+ echo Built
Original file line number Diff line number Diff line change 1+ #! bin/bash
2+
3+ echo " Building..."
4+ go build -o ./bin/GoFileEncoder ./src/
5+ echo " Built"
Original file line number Diff line number Diff line change 1+ @ echo off
2+ call .\build.bat
3+ .\bin\GoFileEncoder.exe
Original file line number Diff line number Diff line change 1+ #! bin/bash
2+ ./build.sh
3+ ./bin/GoFileEncoder
Original file line number Diff line number Diff line change 1+ module GoFileEncoder
2+
3+ go 1.24.2
4+
5+ require github.com/sqweek/dialog v0.0.0-20240226140203-065105509627
6+
7+ require github.com/TheTitanrain/w32 v0.0.0-20200114052255-2654d97dbd3d // indirect
Original file line number Diff line number Diff line change 1+ github.com/TheTitanrain/w32 v0.0.0-20180517000239-4f5cfb03fabf h1:FPsprx82rdrX2jiKyS17BH6IrTmUBYqZa/CXT4uvb+I =
2+ github.com/TheTitanrain/w32 v0.0.0-20180517000239-4f5cfb03fabf /go.mod h1:peYoMncQljjNS6tZwI9WVyQB3qZS6u79/N3mBOcnd3I =
3+ github.com/TheTitanrain/w32 v0.0.0-20200114052255-2654d97dbd3d h1:2xp1BQbqcDDaikHnASWpVZRjibOxu7y9LhAv04whugI =
4+ github.com/TheTitanrain/w32 v0.0.0-20200114052255-2654d97dbd3d /go.mod h1:peYoMncQljjNS6tZwI9WVyQB3qZS6u79/N3mBOcnd3I =
5+ github.com/sqweek/dialog v0.0.0-20240226140203-065105509627 h1:2JL2wmHXWIAxDofCK+AdkFi1KEg3dgkefCsm7isADzQ =
6+ github.com/sqweek/dialog v0.0.0-20240226140203-065105509627 /go.mod h1:/qNPSY91qTz/8TgHEMioAUc6q7+3SOybeKczHMXFcXw =
Original file line number Diff line number Diff line change 1+ @ echo off
2+ .\bin\GoFileEncoder.exe
Original file line number Diff line number Diff line change 1+ #! bin/bash
2+ ./bin/GoFileEncoder
Original file line number Diff line number Diff line change 1+ package main
2+
3+ import (
4+ "GoFileEncoder/src/decoder"
5+ "GoFileEncoder/src/encoder"
6+ "fmt"
7+ "strings"
8+ "time"
9+ )
10+
11+ func main () {
12+ fmt .Print ("Que voulez-vous faire ?\n - Encoder un fichier (e)\n - Décoder un fichier (d)\n " )
13+ var rep string = ""
14+
15+ for ! (rep == "e" || rep == "d" ) {
16+ fmt .Print ("(e/d)>>>" )
17+ fmt .Scanf ("%s\n " , & rep )
18+ rep = strings .ToLower (rep )
19+ time .Sleep (300 * time .Millisecond )
20+ }
21+
22+ switch rep {
23+ case "e" :
24+ encoder .Encoder ()
25+ case "d" :
26+ decoder .Decoder ()
27+ }
28+ }
You can’t perform that action at this time.
0 commit comments