Browse Source

First commit

Frederic G. MARAND 4 years ago
commit
9fc7c99219
5 changed files with 75 additions and 0 deletions
  1. 3 0
      .gitignore
  2. 34 0
      .goreleaser.yml
  3. 21 0
      .run/Run.run.xml
  4. 3 0
      go.mod
  5. 14 0
      main.go

+ 3 - 0
.gitignore

@@ -0,0 +1,3 @@
+.idea
+.gitea_token.txt
+dist

+ 34 - 0
.goreleaser.yml

@@ -0,0 +1,34 @@
+# This is an example goreleaser.yaml file with some sane defaults.
+# Make sure to check the documentation at http://goreleaser.com
+archives:
+  - replacements:
+      darwin: Darwin
+      linux: Linux
+      windows: Windows
+      386: i386
+      amd64: x86_64
+before:
+  hooks:
+    # You may remove this if you don't use go modules.
+    - go mod download
+    # you may remove this if you don't need go generate
+    - go generate ./...
+builds:
+- env:
+  - CGO_ENABLED=0
+changelog:
+  sort: asc
+  filters:
+    exclude:
+      - '^docs:'
+      - '^test:'
+checksum:
+  name_template: 'checksums.txt'
+env_files:
+  gitea_token: ./gitea_token.txt
+gitea_urls:
+  api: https://code.osinet.fr/api/v1/
+  skip_tls_verify: false
+project_name: released
+snapshot:
+  name_template: "{{ .Tag }}-next"

+ 21 - 0
.run/Run.run.xml

@@ -0,0 +1,21 @@
+<component name="ProjectRunConfigurationManager">
+  <configuration default="false" name="Run" type="GoApplicationRunConfiguration" factoryName="Go Application" singleton="false">
+    <module name="released" />
+    <working_directory value="$PROJECT_DIR$" />
+    <EXTENSION ID="net.ashald.envfile">
+      <option name="IS_ENABLED" value="false" />
+      <option name="IS_SUBST" value="false" />
+      <option name="IS_PATH_MACRO_SUPPORTED" value="false" />
+      <option name="IS_IGNORE_MISSING_FILES" value="false" />
+      <option name="IS_ENABLE_EXPERIMENTAL_INTEGRATIONS" value="false" />
+      <ENTRIES>
+        <ENTRY IS_ENABLED="true" PARSER="runconfig" />
+      </ENTRIES>
+    </EXTENSION>
+    <kind value="PACKAGE" />
+    <filePath value="$PROJECT_DIR$/main.go" />
+    <package value="code.osinet.fr/fgm/released" />
+    <directory value="$PROJECT_DIR$/" />
+    <method v="2" />
+  </configuration>
+</component>

+ 3 - 0
go.mod

@@ -0,0 +1,3 @@
+module code.osinet.fr/fgm/released
+
+go 1.14

+ 14 - 0
main.go

@@ -0,0 +1,14 @@
+// main.go
+package main
+
+import "fmt"
+
+var (
+	version = "dev-default"
+	commit  = "none"
+	date    = "unknown" // RFC3339
+)
+
+func main() {
+	fmt.Printf("Version %s, commmit %s, date: %v\n", version, commit, date)
+}