diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c0f2eaa..a5a3ded 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,13 +2,10 @@ name: Actions CI on: push -env: - CUATRO_HEX_KEY: ${{ secrets.CUATRO_HEX_KEY }} - jobs: bless: name: Bless - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest env: MIX_ENV: test @@ -51,7 +48,6 @@ jobs: run: | mix local.rebar --force mix local.hex --force - mix hex.organization auth cuatro --key $CUATRO_HEX_KEY mix deps.get - name: Compile dependencies @@ -72,12 +68,14 @@ jobs: publish-hex-package: name: Publish Hex Package ⬆️☁️ - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest if: startsWith(github.ref, 'refs/tags/v') env: MIX_ENV: dev needs: - bless + permissions: + contents: write steps: - name: Checkout @@ -118,7 +116,6 @@ jobs: run: | mix local.rebar --force mix local.hex --force - mix hex.organization auth cuatro --key $CUATRO_HEX_KEY mix deps.get - name: Compile dependencies @@ -141,28 +138,14 @@ jobs: - name: Create a GitHub Release id: create_release - uses: NFIBrokerage/create-release@v4 + uses: elgohr/Github-Release-Action@v5 env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: - tag_name: ${{ env.TAG }} - name: Release ${{ env.TAG }} - draft: false + title: Release ${{ env.TAG }} prerelease: false - name: Publish library run: mix hex.publish --yes env: HEX_API_KEY: ${{ secrets.HEX_PUBLISH_KEY }} - - - name: Notify ops channel of build success - run: > - curl - -X POST - -H 'Content-type:application/json' - -d "{\"text\":\":hexpm: package published for $REPOSITORY $(git tag -ln $TAG)\"}" - $SLACK_WEBHOOK - env: - SLACK_WEBHOOK: ${{ secrets.OPS_CHANNEL_SLACK_WEBHOOK }} - -# Generated by Elixir.Gaas.Generators.Simple.Actions.LibraryCi diff --git a/.github/workflows/refresh-dev-cache.yml b/.github/workflows/refresh-dev-cache.yml index 03059da..a8b36bc 100644 --- a/.github/workflows/refresh-dev-cache.yml +++ b/.github/workflows/refresh-dev-cache.yml @@ -25,13 +25,10 @@ on: # Would like to run this as a scheduled workflow, but that is not currently # supported by the actions/cache action. -env: - CUATRO_HEX_KEY: ${{ secrets.CUATRO_HEX_KEY }} - jobs: refresh-dev-cache: name: Refresh Dev Cache - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest env: MIX_ENV: dev @@ -74,7 +71,6 @@ jobs: run: | mix local.rebar --force mix local.hex --force - mix hex.organization auth cuatro --key $CUATRO_HEX_KEY mix deps.get - name: Compile dependencies @@ -83,5 +79,3 @@ jobs: - name: Compile application run: mix compile - -# Generated by Elixir.Gaas.Generators.Simple.Actions.RefreshDevCache diff --git a/.tool-versions b/.tool-versions index 0301c4e..9c71c0d 100644 --- a/.tool-versions +++ b/.tool-versions @@ -1,2 +1,2 @@ -elixir 1.11.0-otp-22 -erlang 22.3 +elixir 1.17.3-otp-27 +erlang 27.1 diff --git a/CHANGELOG.md b/CHANGELOG.md index 48dd945..187cbd8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,7 +18,7 @@ Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to - Updated `actions/checkout@` from `v3` to `v4` in GH actions - Updated `actions/cache@` from `v3` to `v4` in GH actions -- Updated `NFIBrokerage/create-release@` from `v3` to `v4` in GH actions +- Updated `CuatroElixir/create-release@` from `v3` to `v4` in GH actions ## 0.8.1 - 2023-08-24 @@ -26,8 +26,8 @@ Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to - Updated `actions/checkout@` from `v1` to `v3` in GH actions - Updated `actions/cache@` from `v1` to `v3` in GH actions -- Updated `NFIBrokerage/create-release@` from `v2` to `v3` in GH actions -- Change `release_name` to `name` field in `NFIBrokerage/create-release@v3` +- Updated `CuatroElixir/create-release@` from `v2` to `v3` in GH actions +- Change `release_name` to `name` field in `CuatroElixir/create-release@v3` action in GH actions - Fixed credo warnings @@ -235,7 +235,3 @@ Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to ## initial commit - 2020-08-19 ### Added - -- This project was generated by Gaas - - diff --git a/LICENSE b/LICENSE index 953d159..690c725 100644 --- a/LICENSE +++ b/LICENSE @@ -174,5 +174,3 @@ of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS - -# Generated by Elixir.Gaas.Generators.Simple.License diff --git a/README.md b/README.md index 071db4e..b10fe1f 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Harness -![Actions CI](https://github.com/NFIBrokerage/harness/workflows/Actions%20CI/badge.svg) +![Actions CI](https://github.com/CuatroElixir/harness/workflows/Actions%20CI/badge.svg) A command line tool for harnessing Elixir boilerplate. @@ -41,4 +41,4 @@ asdf global elixir 1.10.4-otp-22 mix archive.install hex harness --force ``` -[harness-dotfiles]: https://github.com/NFIBrokerage/harness_dotfiles +[harness-dotfiles]: https://github.com/CuatroElixir/harness_dotfiles diff --git a/catalog-info.yaml b/catalog-info.yaml index 7d23f93..34ba78d 100644 --- a/catalog-info.yaml +++ b/catalog-info.yaml @@ -7,9 +7,9 @@ metadata: files locally and versions them, allowing you to semantically version your service chasses. annotations: - github.com/project-slug: NFIBrokerage/harness - backstage.io/source-ref: https://github.com/NFIBrokerage/harness - backstage.io/github-actions-id: https://github.com/NFIBrokerage/harness + github.com/project-slug: CuatroElixir/harness + backstage.io/source-ref: https://github.com/CuatroElixir/harness + backstage.io/github-actions-id: https://github.com/CuatroElixir/harness tags: - config - eex diff --git a/config/config.exs b/config/config.exs index 7b2fcaf..becde76 100644 --- a/config/config.exs +++ b/config/config.exs @@ -1,3 +1 @@ -use Mix.Config - -# Generated by Elixir.Gaas.Generators.Simple.ConfigConfig +import Config diff --git a/mix.exs b/mix.exs index 9dd317e..5f17ac2 100644 --- a/mix.exs +++ b/mix.exs @@ -3,12 +3,18 @@ defmodule Harness.MixProject do @version_file Path.join(__DIR__, ".version") @external_resource @version_file - @source_url "https://github.com/NFIBrokerage/harness" + @source_url "https://github.com/CuatroElixir/harness" + @version (case Regex.run(~r/^v([\d\.\w-]+)/, File.read!(@version_file), + capture: :all_but_first + ) do + [version] -> version + nil -> "0.0.0" + end) def project do [ app: :harness, - version: version() || "0.0.0", + version: @version, elixir: "~> 1.9", elixirc_paths: elixirc_paths(Mix.env()), start_permanent: Mix.env() == :prod, @@ -28,16 +34,6 @@ defmodule Harness.MixProject do ] end - defp version do - Regex.run( - ~r/^v([\d\.]+)/, - File.read!(@version_file), - capture: :all_but_first - ) - |> List.wrap() - |> List.first() - end - defp elixirc_paths(:test), do: ["lib", "test/fixtures"] defp elixirc_paths(_), do: ["lib"] @@ -53,7 +49,7 @@ defmodule Harness.MixProject do {:ex_doc, ">= 0.0.0", only: :dev, runtime: false}, # test {:bless, "~> 1.0", only: :test}, - {:convene, "~> 0.2", organization: "cuatro", only: :test}, + {:credo, "~> 1.7", only: :test}, {:excoveralls, "~> 0.7", only: :test} ] end diff --git a/mix.lock b/mix.lock index 4b93e56..209b1ba 100644 --- a/mix.lock +++ b/mix.lock @@ -1,12 +1,11 @@ %{ "bless": {:hex, :bless, "1.2.0", "5e8190738dcf2fedcbcee2433b44f0e4629a1b0ce84052e5ba17f8dff48d42bd", [:mix], [], "hexpm", "046692560e401dc33c2bb3223bb3f210c18fafbae24431f0056516bb5c8be805"}, - "bunt": {:hex, :bunt, "0.2.1", "e2d4792f7bc0ced7583ab54922808919518d0e57ee162901a16a1b6664ef3b14", [:mix], [], "hexpm", "a330bfb4245239787b15005e66ae6845c9cd524a288f0d141c148b02603777a5"}, - "convene": {:hex, :convene, "0.2.2", "2495b032aff9a8d5b87b5db83c64e65a90e61d438dda2f72fc951d2093ceaea3", [:mix], [{:credo, "~> 1.4", [hex: :credo, repo: "hexpm", optional: false]}], "hexpm:cuatro", "83e0a113b38315091e5d65fc12f02f1f518b317eee9bf9dfe3dd01efb64ece51"}, - "credo": {:hex, :credo, "1.7.0", "6119bee47272e85995598ee04f2ebbed3e947678dee048d10b5feca139435f75", [:mix], [{:bunt, "~> 0.2.1", [hex: :bunt, repo: "hexpm", optional: false]}, {:file_system, "~> 0.2.8", [hex: :file_system, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "6839fcf63d1f0d1c0f450abc8564a57c43d644077ab96f2934563e68b8a769d7"}, + "bunt": {:hex, :bunt, "1.0.0", "081c2c665f086849e6d57900292b3a161727ab40431219529f13c4ddcf3e7a44", [:mix], [], "hexpm", "dc5f86aa08a5f6fa6b8096f0735c4e76d54ae5c9fa2c143e5a1fc7c1cd9bb6b5"}, + "credo": {:hex, :credo, "1.7.15", "283da72eeb2fd3ccf7248f4941a0527efb97afa224bcdef30b4b580bc8258e1c", [:mix], [{:bunt, "~> 0.2.1 or ~> 1.0", [hex: :bunt, repo: "hexpm", optional: false]}, {:file_system, "~> 0.2 or ~> 1.0", [hex: :file_system, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "291e8645ea3fea7481829f1e1eb0881b8395db212821338e577a90bf225c5607"}, "earmark_parser": {:hex, :earmark_parser, "1.4.33", "3c3fd9673bb5dcc9edc28dd90f50c87ce506d1f71b70e3de69aa8154bc695d44", [:mix], [], "hexpm", "2d526833729b59b9fdb85785078697c72ac5e5066350663e5be6a1182da61b8f"}, "ex_doc": {:hex, :ex_doc, "0.30.5", "aa6da96a5c23389d7dc7c381eba862710e108cee9cfdc629b7ec021313900e9e", [:mix], [{:earmark_parser, "~> 1.4.31", [hex: :earmark_parser, repo: "hexpm", optional: false]}, {:makeup_elixir, "~> 0.14", [hex: :makeup_elixir, repo: "hexpm", optional: false]}, {:makeup_erlang, "~> 0.1", [hex: :makeup_erlang, repo: "hexpm", optional: false]}], "hexpm", "88a1e115dcb91cefeef7e22df4a6ebbe4634fbf98b38adcbc25c9607d6d9d8e6"}, "excoveralls": {:hex, :excoveralls, "0.17.0", "279f124dba347903bb654bc40745c493ae265d45040001b4899ea1edf88078c7", [:mix], [{:castore, "~> 1.0", [hex: :castore, repo: "hexpm", optional: true]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "08b638d114387a888f9cb8d65f2a0021ec04c3e447b793efa7c1e734aba93004"}, - "file_system": {:hex, :file_system, "0.2.10", "fb082005a9cd1711c05b5248710f8826b02d7d1784e7c3451f9c1231d4fc162d", [:mix], [], "hexpm", "41195edbfb562a593726eda3b3e8b103a309b733ad25f3d642ba49696bf715dc"}, + "file_system": {:hex, :file_system, "1.1.1", "31864f4685b0148f25bd3fbef2b1228457c0c89024ad67f7a81a3ffbc0bbad3a", [:mix], [], "hexpm", "7a15ff97dfe526aeefb090a7a9d3d03aa907e100e262a0f8f7746b78f8f87a5d"}, "jason": {:hex, :jason, "1.4.1", "af1504e35f629ddcdd6addb3513c3853991f694921b1b9368b0bd32beb9f1b63", [:mix], [{:decimal, "~> 1.0 or ~> 2.0", [hex: :decimal, repo: "hexpm", optional: true]}], "hexpm", "fbb01ecdfd565b56261302f7e1fcc27c4fb8f32d56eab74db621fc154604a7a1"}, "makeup": {:hex, :makeup, "1.1.0", "6b67c8bc2882a6b6a445859952a602afc1a41c2e08379ca057c0f525366fc3ca", [:mix], [{:nimble_parsec, "~> 1.2.2 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "0a45ed501f4a8897f580eabf99a2e5234ea3e75a4373c8a52824f6e873be57a6"}, "makeup_elixir": {:hex, :makeup_elixir, "0.16.1", "cc9e3ca312f1cfeccc572b37a09980287e243648108384b97ff2b76e505c3555", [:mix], [{:makeup, "~> 1.0", [hex: :makeup, repo: "hexpm", optional: false]}, {:nimble_parsec, "~> 1.2.3 or ~> 1.3", [hex: :nimble_parsec, repo: "hexpm", optional: false]}], "hexpm", "e127a341ad1b209bd80f7bd1620a15693a9908ed780c3b763bccf7d200c767c6"}, diff --git a/test/harness_test.exs b/test/harness_test.exs index b4799fb..59cc56c 100644 --- a/test/harness_test.exs +++ b/test/harness_test.exs @@ -1,5 +1,3 @@ defmodule HarnessTest do use ExUnit.Case end - -# Generated by Elixir.Gaas.Generators.Simple.BaseModuleTest diff --git a/test/test_helper.exs b/test/test_helper.exs index 11bbac8..869559e 100644 --- a/test/test_helper.exs +++ b/test/test_helper.exs @@ -1,3 +1 @@ ExUnit.start() - -# Generated by Elixir.Gaas.Generators.Simple.TestHelper