Is there a way to hide root?

is there a way to hide root from the theia app? or prevent the operations on the file like delete?

[original thread by designerbase]

Could you elaborate what do you mean by root?

You can unbind fs commands with the custom contribution. But a user can always use a terminal to perfrom them. If you want really restrict user access, then you should configure user os.

[designerbase]

root file i mean now we can remove files using delete option from theia menu… like edit-> delete, i want to disable that feature. for terminal ill configure in the os.

[designerbase]

i am using docker

[designerbase]

sorry not from edit-> delete. we can delete files using right click and delete

Navigator shows what os allows to access. If you restrict OS then the navigator should not show inaccessible files.

to unregister a command, you need to call CommandRegistry.unregisterCommand with a proper id. Search into Theia codebase commands using labels from UI and then use their IDs.

[designerbase]

i am using docker to configure theia. so what should i do in the docker file?

in docker you should only mount what you want to have, it does not have access to host fs by default