Skip to content
This repository was archived by the owner on Nov 27, 2025. It is now read-only.

Support for YAML files in solutions and a solution fix - #316

Merged
pnickolov merged 5 commits into
mainfrom
pn/yaml-manifests
Mar 20, 2024
Merged

pnickolov merged 5 commits into
mainfrom
pn/yaml-manifests

Conversation

@pnickolov

Copy link
Copy Markdown
Contributor

Description

Added support for YAML files in solutions.

Added a new command, solution fix to make common changes to solutions.

Details

  1. When doing solution init, you can now provide a --yaml flag, which will make the manifest saved in a YAML format. A solution can have only one manifest, either YAML or JSON (having both will produce an error)
  2. When adding new objects with solution extend --add-xxx, new objects are now added in the same format as the manifest. (You can also override this by specifying a --json or --yaml flag to get the object created with a different format; mostly for those who what to try the YAML format but not ready to switch the whole solution)
  3. There is also a new command fsoc solution fix which, similar to go fix (in Go) and cargo fix (in Rust), will make common adjustments to your solution to adapt to recent changes in platform capabilities. We now support two "fixes":
    --manifest-format=yaml|json -- will rewrite your solution's manifest to the desired format
    --manifest-version -- will convert and rewrite your manifest into the latest manifest version (1.1.0 from 1.0.0), adding the solution type as needed.

Type of Change

  • Bug Fix
  • New Feature
  • Breaking Change
  • Refactor
  • Documentation
  • Other (please describe)

Checklist

  • I have read the contributing guidelines
  • Existing issues have been referenced (where applicable)
  • I have verified this change is not present in other open pull requests
  • Functionality is documented
  • All code style checks pass
  • New code contribution is covered by automated tests
  • All new and existing tests pass

@pnickolov
pnickolov merged commit f4d0152 into main Mar 20, 2024
@pnickolov
pnickolov deleted the pn/yaml-manifests branch March 20, 2024 08:14
@ikstewa

ikstewa commented Mar 21, 2024

Copy link
Copy Markdown

@pnickolov When running this on the latest release it doesn't appear to function as the provided example:

❯   fsoc solution fix --manifest-type=yaml --manifest-version

Error: unknown flag: --manifest-type
Usage:
  fsoc solution fix [flags]

Examples:
  fsoc solution fix --manifest-type=yaml --manifest-version

@pnickolov

Copy link
Copy Markdown
Contributor Author

@ikstewa sorry, the example is wrong... please use --manifest-format=yaml (per fsoc help solution fix).
I'll correct the example in the next release, thank you for reporting it!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

⌂ 换网址