I'm using colab on python3 how to view or show hidden files
like in this image I can't see the hidden files(. files)
now they updated the site with a eye symbol indicating hidden items
Meanwhile a clumsy workaround would be to use i.e !cp to copy the files to your google drive storage (if you have one), make the changes and copy them back. Example:
from google.colab import drive
drive.mount("/content/gdrive")
%cd /root
%ls -a
> .cache/ .gsutil/ .local/ .tmux.conf* ... .bashrc* ...
!cp /root/.bashrc* /content/gdrive/folder
#make changes on bashrc and copy back
!cp /content/gdrive/folder/.bashrc /root/.bashrc
Since i'm using colab-ssh + github + vscode i can browse all folders and files inside vscode and make changes there. But this setup requires some preliminary work.
A faster way is to register for a free ngrok account, copy the authtoken and run following commands:
!pip install colabcode
from colabcode import ColabCode
ColabCode(password="anything", authtoken="your token")
.
.
.
Code Server can be accessed on: NgrokTunnel: "https://8348-34-125-56-97.ngrok.io" -> "http://localhost:10000"
[2022-03-31T08:01:58.749Z] info code-server 3.10.2 387b12ef4ca404ffd39d84834e1f0776e9e3c005
[2022-03-31T08:01:58.751Z] info Using user-data-dir ~/.local/share/code-server
..
..
After clicking the ngrok.io link you have to insert your password. Once the editor opens, you can click on "open folder", choose the base "/ " folder. And there you can browse through all files and make changes directly in the editors interface:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With