Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update configuration action #29

Open
whilefoo opened this issue Oct 21, 2024 · 4 comments
Open

Update configuration action #29

whilefoo opened this issue Oct 21, 2024 · 4 comments

Comments

@whilefoo
Copy link

The update-configuration.yml doesn't apply formatting according to the prettier configuration

Also I think it would be better to make this a custom action which would prevent duplication, we can use Typescript instead of writing code in the YML and allow us to change it without having to apply changes to every repo that forks plugin-template.

The only question is how to specify where the schema is located in the code, it could be something like this:

- name: update configuration
  uses: ubiquity-os/update-configuration
  with:
    filepath: './src/types'
    typeboxSchemaName: 'pluginSettingsSchema'

and then we can dynamically import it!

In the future we could also support different schema libraries (zod, joi...)

@0x4007 rfc

@gentlementlegen
Copy link
Member

gentlementlegen commented Oct 22, 2024

It used to format with prettier:
https://github.com/ubiquity-os/action-deploy-plugin/blob/main/action.yml#L124

Also be careful not to run prettier on the dist otherwise it will segfault.


Edit: I see now that the template does not use the custom action I wrote for that which makes sense now. Should be changed to something like https://github.com/ubiquity-os-marketplace/text-conversation-rewards/blob/development/.github/workflows/update-configuration.yml

@0x4007
Copy link
Member

0x4007 commented Oct 22, 2024

Also be careful not to run prettier on the dist otherwise it will segfault.

segfaults aren't really a thing in the world of TypeScript - are you referring to prettier crashing due to memory constraints?

Will importing the custom action close this issue?

@gentlementlegen
Copy link
Member

Node will overflow in memory, which I believe technically is a segfault (triggers a sigsegv), force of habit to use that word. Yes I believe using the custom action should resolve this issue.

@whilefoo
Copy link
Author

Oh I didn't notice that updating manifest is now part of the deploy action.

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

No branches or pull requests

3 participants