diff --git a/CHANGELOG.md b/CHANGELOG.md index b710bdb..c218233 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,8 +6,12 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog). #### [Unreleased](https://github.com/i18nhero/cli/compare/v0.0.2...HEAD) +- chore: bump package version to v0.0.3-dev [`#82`](https://github.com/i18nhero/cli/pull/82) + #### [v0.0.2](https://github.com/i18nhero/cli/compare/v0.0.1...v0.0.2) +> 12 November 2024 + - chore: prepare v0.0.2 release [`#81`](https://github.com/i18nhero/cli/pull/81) - refactor: use new public api [`#80`](https://github.com/i18nhero/cli/pull/80) - chore: bump package version to v0.0.2-dev [`#79`](https://github.com/i18nhero/cli/pull/79) diff --git a/Cargo.lock b/Cargo.lock index b1fc337..72b2614 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -671,7 +671,7 @@ dependencies = [ [[package]] name = "i18nhero" -version = "0.0.2" +version = "0.0.3-dev" dependencies = [ "bytes", "clap", @@ -697,7 +697,7 @@ dependencies = [ [[package]] name = "i18nhero-codegen" -version = "0.0.2" +version = "0.0.3-dev" dependencies = [ "anyhow", "i18nhero", diff --git a/Cargo.toml b/Cargo.toml index def531d..1a6d0a0 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -3,7 +3,7 @@ members = ["packages/i18nhero", "packages/i18nhero-codegen"] resolver = "2" [workspace.package] -version = "0.0.2" +version = "0.0.3-dev" authors = ["Mads Hougesen "] edition = "2021" license = "MIT" @@ -38,7 +38,7 @@ dirs = { version = "5.0.1" } git2 = { version = "0.19.0", default-features = false, features = [ "vendored-libgit2", ] } -i18nhero = { path = "packages/i18nhero", version = "0.0.2" } +i18nhero = { path = "packages/i18nhero", version = "0.0.3-dev" } json_comments = "0.2.2" regex = "1.11.1" reqwest = { version = "0.12.9", default-features = false, features = [ diff --git a/README.md b/README.md index d17bba8..ad68687 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ This tool allows you to manage your [i18nhero](https://i18nhero.com) locale file ``` -i18nhero 0.0.2 +i18nhero 0.0.3-dev CLI tool for interacting with locales hosted on i18nhero.com Usage: i18nhero diff --git a/schemas/v0.0.3-dev/i18nhero.schema.json b/schemas/v0.0.3-dev/i18nhero.schema.json new file mode 100644 index 0000000..4f8e728 --- /dev/null +++ b/schemas/v0.0.3-dev/i18nhero.schema.json @@ -0,0 +1,59 @@ +{ + "$schema": "http://json-schema.org/draft-07/schema#", + "title": "CliConfig", + "type": "object", + "required": ["output", "project_id"], + "properties": { + "$schema": { + "default": "https://raw.githubusercontent.com/i18nhero/cli/main/schemas/v0.0.3-dev/i18nhero.schema.json", + "type": "string" + }, + "output": { + "description": "Configuration for downloading and uploading locale files.", + "allOf": [ + { + "$ref": "#/definitions/CliConfigOutput" + } + ] + }, + "project_id": { + "description": "Used to define the linked project.", + "type": "string" + } + }, + "definitions": { + "CliConfigOutput": { + "type": "object", + "properties": { + "flat": { + "description": "Defines whether the locale files should be a flat `string <-> string` map or a multi layered map.\n\nA point (`.`) in the identifier name is used to define multi-layered keys when `flat` is set to false.\n\nThe identifier `pages.dashboard.title` will be expanded to the following:\n\n```json { \"pages\": { \"dashboard\": { \"title\": \"\" } } } ```", + "default": false, + "type": ["boolean", "null"] + }, + "format": { + "description": "Defines the file format used when uploading and downloading locale files.", + "default": "json", + "allOf": [ + { + "$ref": "#/definitions/CliConfigOutputFormat" + } + ] + }, + "keep_empty_fields": { + "description": "Defines whether identifiers that are missing translations should be downloaded.", + "default": false, + "type": ["boolean", "null"] + }, + "path": { + "description": "Defines where locale files should be downloaded to, and uploaded from.", + "default": "lang", + "type": "string" + } + } + }, + "CliConfigOutputFormat": { + "type": "string", + "enum": ["json", "yaml"] + } + } +}