Skip to content

Releases: no-problem-dev/swift-env

2.0.0

Choose a tag to compare

@github-actions github-actions released this 11 Aug 07:40

Removed

  • The @_exported re-export of swift-configuration. Code naming ConfigReader, ConfigKey, or
    EnvironmentVariablesProvider — including anything calling the generated load() — must now
    import Configuration alongside import Env.

Added

  • .spi.yml, so Swift Package Index builds and hosts the DocC documentation
  • CONTRIBUTING.md
  • scripts/release.sh and scripts/compute-next-version.sh, which derive the next version from
    the public API diff and stamp it into this file

Changed

  • CI no longer builds or tests; it creates a GitHub Release from a pushed tag. Verification runs
    locally before pushing.

1.0.4

Choose a tag to compare

@github-actions github-actions released this 19 Jul 09:08

Full Changelog: v1.0.3...1.0.4

v1.0.3

Choose a tag to compare

@github-actions github-actions released this 02 Jan 07:08
305c7e0

🎉 v1.0.3 リリース

swift-env v1.0.3 がリリースされました。

📝 変更内容

変更

  • 依存関係指定を .upToNextMajor に統一

📦 インストール

dependencies: [
    .package(url: "https://github.com/no-problem-dev/swift-env.git", .upToNextMajor(from: "1.0.3"))
]

🔗 リンク

v1.0.2

Choose a tag to compare

@github-actions github-actions released this 02 Jan 07:00
39d357b

🎉 v1.0.2 リリース

swift-env v1.0.2 がリリースされました。

📝 変更内容

変更

  • Swift 6.2 対応: Swift 6.2 安定版に対応
    • swift-tools-version: 6.0 → 6.2
    • swift-syntax: 600.0.0 → 602.0.0

CI

  • Linux x86_64 テスト追加: swift:6.2-bookworm コンテナでテスト実行

📦 インストール

dependencies: [
    .package(url: "https://github.com/no-problem-dev/swift-env.git", .upToNextMajor(from: "1.0.2"))
]

🔗 リンク

v1.0.1

Choose a tag to compare

@github-actions github-actions released this 02 Jan 04:26
77f6aeb

🎉 v1.0.1 リリース

swift-env v1.0.1 がリリースされました。

📝 変更内容

追加

  • @EnvGroup マクロ: 複数の @Env 構造体を集約するファサード構造体を生成
    • static func load() メソッドを自動生成し、全ネスト設定を一括読み込み
    • ネストした @Env および @EnvGroup 構造体をサポート
    • 統一されたエントリーポイントでアプリケーション設定を簡潔に管理

テスト

  • EnvGroup マクロ展開テスト追加

📦 インストール

dependencies: [
    .package(url: "https://github.com/no-problem-dev/swift-env.git", .upToNextMajor(from: "1.0.1"))
]

🔗 リンク

v1.0.0

Choose a tag to compare

@github-actions github-actions released this 02 Jan 04:14
3cc63c1

🎉 v1.0.0 リリース

swift-env v1.0.0 がリリースされました。

📝 変更内容

追加

  • @Env マクロ: 構造体に付与して環境変数設定を自動生成

    • Keys enum(ConfigKey型の静的プロパティ)を自動生成
    • Defaults enum(デフォルト値の静的プロパティ)を自動生成
    • init(config: ConfigReader) イニシャライザを自動生成
    • Sendable プロトコル準拠を自動追加
    • scope パラメータでスコープ設定をサポート
  • @Value マクロ: プロパティに付与して環境変数キーとデフォルト値を指定

    • String, Int, Double, Bool 型をサポート
    • 環境変数キーをドット区切りで指定(例: "gcp.project.id" → GCP_PROJECT_ID)
  • Apple swift-configuration 1.0 の再エクスポート

    • ConfigReader, ConfigKey, EnvironmentVariablesProvider 等を利用可能

テスト

  • 11種類のマクロ展開テスト
    • 基本型テスト(String, Int, Double, Bool)
    • 複数プロパティテスト
    • スコープ付きテスト
    • エッジケーステスト

ドキュメント

  • README.md(日本語)
  • RELEASE_PROCESS.md
  • DocCドキュメント

📦 インストール

dependencies: [
    .package(url: "https://github.com/no-problem-dev/swift-env.git", .upToNextMajor(from: "1.0.0"))
]

🔗 リンク