Skip to content

Commit

Permalink
gleam 1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
TanklesXL committed Mar 6, 2024
1 parent cc0fd0d commit c424062
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 17 deletions.
4 changes: 2 additions & 2 deletions .github/actions/test/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ inputs:
gleam-version:
description: gleam version
required: false
default: 1.0.0-rc2
default: "~> 1.0"
erlang-version:
description: erlang-otp version
required: false
default: 26.2.2
default: "~> 26.2"

runs:
using: composite
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
erlang: ["26.2.2"]
erlang: ["~> 26.2"]
steps:
- uses: actions/checkout@v2
- uses: ./.github/actions/test
Expand Down
12 changes: 6 additions & 6 deletions gleam.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@ repository = { type = "github", user = "TanklesXL", repo = "gladvent" }
description = "An Advent Of Code runner for gleam"
licences = ["Apache-2.0"]
internal_modules = ["gladvent/internal/*"]
gleam = "~> 0.34 or ~> 1.0"
gleam = "~> 1.0"

[dependencies]
gleam_stdlib = "~> 0.34 or ~> 1.0"
gleam_otp = "~> 0.4"
gleam_erlang = "~> 0.7"
snag = "~> 0.2"
glint = " ~> 0.16.0"
glint = "~> 0.17"
simplifile = "~> 0.3"
argv = "~> 1.0"
shellout = "~> 1.6"
gleam_package_interface = "~> 1.0"
gleam_json = "~> 1.0"
spinner = "~> 1.1"
gleam_stdlib = "~> 0.36 or ~> 1.0"
gleam_otp = "~> 0.4"
gleam_erlang = "~> 0.7"
snag = "~> 0.2"

[dev-dependencies]
gleeunit = "~> 1.0"
4 changes: 2 additions & 2 deletions manifest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ packages = [
{ name = "gleam_stdlib", version = "0.36.0", build_tools = ["gleam"], requirements = [], otp_app = "gleam_stdlib", source = "hex", outer_checksum = "C0D14D807FEC6F8A08A7C9EF8DFDE6AE5C10E40E21325B2B29365965D82EB3D4" },
{ name = "glearray", version = "0.2.1", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "glearray", source = "hex", outer_checksum = "908154F695D330E06A37FAB2C04119E8F315D643206F8F32B6A6C14A8709FFF4" },
{ name = "gleeunit", version = "1.0.2", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "gleeunit", source = "hex", outer_checksum = "D364C87AFEB26BDB4FB8A5ABDE67D635DC9FA52D6AB68416044C35B096C6882D" },
{ name = "glint", version = "0.16.0", build_tools = ["gleam"], requirements = ["gleam_community_ansi", "gleam_community_colour", "gleam_stdlib", "snag"], otp_app = "glint", source = "hex", outer_checksum = "61B7E85CBB0CCD2FD8A9C7AE06CA97A80BF6537716F34362A39DF9C74967BBBC" },
{ name = "glint", version = "0.17.1", build_tools = ["gleam"], requirements = ["gleam_community_ansi", "gleam_community_colour", "gleam_stdlib", "snag"], otp_app = "glint", source = "hex", outer_checksum = "DF094D7A97C54F4A23F670A7109A188DCBBDD17E003B3E650566835BDBA6BFDF" },
{ name = "repeatedly", version = "2.1.1", build_tools = ["gleam"], requirements = [], otp_app = "repeatedly", source = "hex", outer_checksum = "38808C3EC382B0CD981336D5879C24ECB37FCB9C1D1BD128F7A80B0F74404D79" },
{ name = "shellout", version = "1.6.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "shellout", source = "hex", outer_checksum = "E2FCD18957F0E9F67E1F497FC9FF57393392F8A9BAEAEA4779541DE7A68DD7E0" },
{ name = "simplifile", version = "0.4.0", build_tools = ["gleam"], requirements = ["gleam_stdlib"], otp_app = "simplifile", source = "hex", outer_checksum = "8F3C94B83F691CCFACD784A4D7C1F7E5A0437D93341549B908EE3B32E3477447" },
Expand All @@ -29,7 +29,7 @@ gleam_otp = { version = "~> 0.4" }
gleam_package_interface = { version = "~> 1.0" }
gleam_stdlib = { version = "~> 0.34 or ~> 1.0" }
gleeunit = { version = "~> 1.0" }
glint = { version = " ~> 0.16.0" }
glint = { version = "~> 0.17" }
shellout = { version = "~> 1.6" }
simplifile = { version = "~> 0.3" }
snag = { version = "~> 0.2" }
Expand Down
4 changes: 2 additions & 2 deletions src/gladvent/internal/cmd/run.gleam
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,8 @@ fn gleam_err_to_string(g: GleamErr) -> String {
"at line",
int.to_string(g.line),
g.value
|> option.map(fn(val) { "with value " <> string.inspect(val) })
|> option.unwrap(""),
|> option.map(fn(val) { "with value " <> string.inspect(val) })
|> option.unwrap(""),
],
" ",
)
Expand Down
8 changes: 4 additions & 4 deletions src/gladvent/internal/runners.gleam
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,8 @@ pub fn get_day(

use runner_param_type <- result.try(case parse {
Error(Nil) -> Ok(string)
Ok(package_interface.Function(parameters: [param], return: return, ..)) if param.type_ == string ->
Ok(return)
Ok(package_interface.Function(parameters: [param], return: return, ..)) if param.type_
== string -> Ok(return)
_ ->
Error(ParseFunctionInvalid(
"parse function must have 1 input parameter of type String",
Expand All @@ -162,8 +162,8 @@ pub fn get_day(
pt_1,
pt_2,
parse
|> result.replace(parse_function(module_name))
|> option.from_result,
|> result.replace(parse_function(module_name))
|> option.from_result,
))
}

Expand Down

0 comments on commit c424062

Please sign in to comment.