Skip to content

Conversation

@svastven
Copy link
Contributor

Hi guys 👋

This PR fixes a small bug which would generate Localization..strings file instead of Localization.strings file when using the following configuration:

{
    "defaultFileName": "Localization.string",
    ....
}

The current setup seems to still support default file names with their extension included:

let defaultFileName = defaultFileName.removingSuffix(".strings")
.

However, it only works properly if no extension is included ("defaultFileName": "Localization" as in the example in README). If extension is specified a file with double dot is generated. This is due to the
removingSuffix function only removing suffix.count-1 last characters of the string instead of suffix.count which I think is unexpected.

Checklist

  • Added tests (if applicable)

@olejnjak olejnjak self-requested a review October 16, 2023 10:08
Copy link
Member

@olejnjak olejnjak left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks ❤️

@olejnjak olejnjak merged commit 76ca0bb into AckeeCZ:master Oct 16, 2023
@olejnjak
Copy link
Member

olejnjak commented Oct 16, 2023

Released in 1.6.1 ✅🙂

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants