Posts

Windows terminal tips and tricks

 Windows terminal tips and tricks ctrl+spacebar and select any terminal  alt+f4 - to close window i.e all tabs alt+shift+ plus - to open new terminal by splitting screen horizontally alt+shift+ minus - to open new terminal by splitting screen vertically alt + arros - to toggle between terminals ctrl+shift+w - to close current terminal, on which cusror is placed Customizing power shell in windows terminal: here Customize bash terminal in windows and install ZSH :3 parts part1  (bash customization, 1 and 2 are not much helpful) part2 part3 (For zsh installation and customization) Zsh customization of me and open source: here Install latest ZSH on centos: here  (The default one ships with yum repository was 5.0.2, which doesn't support power10k theme) Install font awesome(This font should be compatible with power10k theme):  yum -y install fontawesome-fonts

Vs Code tips and tricks

 Vs Code tips and tricks: ctrl + r                 :  open recent ctrl+shift+p          :  show all the commands ctrl+ right arrow   : navigate word by word in a file instead of cahracter by character,similarly ctrl+left arrow for backward movement ctrl+shift+a           : to toggle between terminal ctrl+b                     : to toggle sidebar f2                            : move cursor between terminal and editor  In setttings.json: "editor.mouseWheelZoom": true - This will enable zomming the contents of the file by pressing control key and scroll button on mouse. Extensions: Code Runner: if we want to run any programs using click clisk, it will provide small run top on top right corner. Prettier: used for code formatting Bracket pair colo...

Docker

 1. docker run -it <image> <any command like ls>  - It will start the container execute the command and stop the container.The status of the stopped container can be seen using docker ps -a 2. docker run -it --rm <image> <any command like ls> - It will do the same the same hing, but after stopping it will also kills the container 3. If we run an docker image without specifying -d(detached mode),then we will enter into container directly and if we exit the container will be stopped 4.If we run container in detached mode by specifying -d,as shown below image will run in background,we can connect to it using exec. Eg:$docker run -itd <image> 5. About user in docker file: - If we specify any user in dockerfile, all the commands will be executed by that user and in  the image that user is retained, i.e if you make a container out of it,we will get same user. - If we want to switch user,you can do so using another user instruction in docker file an...