Update Readme

Populate CHANGELOG.md based on previous versions
This commit is contained in:
Thibaut Schmitt 2022-11-22 17:54:20 +01:00
parent 9ab7e74991
commit b662fc64f3
2 changed files with 87 additions and 0 deletions

View File

@ -0,0 +1,26 @@
# v1.1 - SwiftUI compatibility
## New
- Update plist `UIAppFonts` when generated fonts (use plistBuddy)
- New parameter: `infoPlistPaths`
- Generate SwiftUI extensions for colors, fonts and images
- New parameter: `extensionNameSwiftUI`
- Adding Makefile to install, unsintall and create man page.
---
## Fixes
Fix SwiftLint rule `trailing_newline`
# v1.0 - Configuration file
## Major
- A new command has been added: `generate`. Instead of runnning every single command, it will run all necessary command based on a `yaml` configuration file. Check out Readme to know more
## Minors
- Code refactoring
- Huge performance improvements
- Readme.md update
- Add option to generate static properties/methods (`staticMembers`)
- Add option to specify the project directory (`--project-directory`). It allows to run ResgenSwift from anywhere
- Add `install.sh` script to install ResgenSwift in `/usr/local/bin`

View File

@ -261,6 +261,67 @@ tags: []
... ...
``` ```
### File architecture
ResgenSwift generate extension of classes. Those classes must exists in your project. You can create them yourself OR you can let ResgenSwift create them by specifying what you want. Do as follow:
```
architecture:
  property: R *(required but not used)*
  classname: R
  path: ./path/to/generate
  children:
    - property: images
      classname: R2Image
    - property: strings
      classname: R2String
    - property: fonts
      classname: R2Font
    - property: images
      classname: R2Image
    - property: uikit
      classname: R2UI
      children:
        - property: images
          classname: R2UIImage
        - property: fonts
          classname: R2UIFont
        - property: images
          classname: R2UIImage
```
This will generate a file named as the architecture classname: `R.swift`. Based on the previous architecture, it will generate:
```
class R {
static let images = R2Image()
static let strings = R2String()
static let fonts = R2Font()
static let images = R2Image()
static let uikit = R2UI()
}
class R2Image {}
class R2String {}
class R2Font {}
class R2Image {}
class R2UI {
let images = R2UIImage()
let fonts = R2UIFont()
let images = R2UIImage()
}
class R2UIImage {}
class R2UIFont {}
class R2UIImage {}
```
### Usage ### Usage
```sh ```sh