Skip to content

Conversation

@Ubayed-Bin-Sufian
Copy link
Contributor

Description

This PR adds Windows OS commands and fixes linting errors.

@Ubayed-Bin-Sufian Ubayed-Bin-Sufian marked this pull request as ready for review February 25, 2025 11:39
@sa-fw-an
Copy link
Member

sa-fw-an commented Feb 25, 2025

@Ubayed-Bin-Sufian I suggest go with the script in Package.json instead of the npx thing. (npm run format:file <file location>)

@Ubayed-Bin-Sufian
Copy link
Contributor Author

Ubayed-Bin-Sufian commented Feb 25, 2025

@Ubayed-Bin-Sufian I suggest go with the script in Package.json instead of the npx thing. (npm run format:file <file location>)

Running the npm run format and npm run format:file <file location> is the same. Whenever I run it, it would run the entire tree of src folder and needs to discard the changes of all the files.

Screenshot (532)

@sa-fw-an
Copy link
Member

U need to configure the Package.json to accept that script before running. @FirePheonix was able to achieve it. Help:)

@FirePheonix
Copy link
Contributor

@Ubayed-Bin-Sufian
So basically, you just have to add a SINGLE under SCRIPTS in package.json:

the line:
"format:file": "prettier --write",

here's the demo video explaining it.
SEE WITH AUDIO

package.mp4

@MostlyKIGuess
Copy link
Member

LGTM, apart from the extra spaces

@Ubayed-Bin-Sufian
Copy link
Contributor Author

Ubayed-Bin-Sufian commented Feb 26, 2025

@Ubayed-Bin-Sufian So basically, you just have to add a SINGLE under SCRIPTS in package.json:

the line: "format:file": "prettier --write",

here's the demo video explaining it. SEE WITH AUDIO

package.mp4

@FirePheonix Thanks for your explanation. I wanted to know should I do it every time before I push a commit?

@Ubayed-Bin-Sufian
Copy link
Contributor Author

@sa-fw-an You may have a look right now.

@sa-fw-an
Copy link
Member

@sa-fw-an You may have a look right now.

I think u were supposed to edit the package.json file and add the line what @FirePheonix has added in the video, and also add that in the docs ;)

@Ubayed-Bin-Sufian
Copy link
Contributor Author

@sa-fw-an Please review.

@sa-fw-an sa-fw-an merged commit 785a12e into sugarlabs:main Feb 27, 2025
1 check passed
@Ubayed-Bin-Sufian Ubayed-Bin-Sufian deleted the windows_OS branch February 27, 2025 19:32
@FirePheonix FirePheonix mentioned this pull request Mar 10, 2025
5 tasks
@sa-fw-an sa-fw-an mentioned this pull request Apr 22, 2025
5 tasks
@sa-fw-an sa-fw-an mentioned this pull request May 27, 2025
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.

4 participants