My WSL terminal lost color


Question For some reason when I start the Ubuntu terminal in Windows, it doesn't show colors until I type bash. What could be the reason and how do I fix it? When I installed WSL it always showed colors. Answer The reason could be a modified .bash_profile file. Try putting these lines to ~/.bash_profile source ~/.bashrc Or a better way is to run the below command from your terminal echo "…
Read more ⟶

Nodejs + npm, installing modules on ntfs partition


Question I have a problem when installing npm modules. NodeJS is installed on Ubuntu 11.10 running on Virtual Box on Windows host. My project files are on NTFS partition (I have to share them with windows). When I try to install some npm module I get an error, and module is not installed. I've found out that problem occurs when npm tries to create symbolic links. Probably you can not create symlinks on NTFS partition, when I'm installing module "…
Read more ⟶

How do I run all my PHPUnit tests?


Question I have script called Script.php and tests for it in Tests/Script.php, but when I run phpunit Tests it does not execute any tests in my test file. How do I run all my tests with phpunit? PHPUnit 3.3.17, PHP 5.2.6-3ubuntu4.2, latest Ubuntu Output: $ phpunit Tests PHPUnit 3.3.17 by Sebastian Bergmann. Time: 0 seconds OK (0 tests, 0 assertions) And here are my script and test files: Script.php <?php function returnsTrue() { return TRUE; } ?…
Read more ⟶

Ubuntu - Installing .net core


Question I want to try out the new .net core. I am following instructs at https://www.microsoft.com/net/core, but it is not working. Reading package lists... Done Building dependency tree Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming.…
Read more ⟶

How to install gtk development dependencies on Ubuntu?


Question I have the code from GTK tutorial in base.c. I am working on Ubuntu and when I compile using $ gcc base.c -o base `pkg-config --cflags --libs gtk+-2.0` I get the following error Package gtk+-2.0 was not found in the pkg-config search path. Perhaps you should add the directory containing `gtk+-2.0.pc' to the PKG_CONFIG_PATH environment variable No package 'gtk+-2.0' found base.c:1:20: fatal error: gtk/gtk.h: No such file or directory compilation terminated.…
Read more ⟶

Script to continuously follow kubectl get pods


Question I'm trying to build a script that can follow(-f) kubectl get pods see a realtime update when I make any changes/delete pods on Ubuntu server. What could be the easiest/efficient way to do so? Answer You can just use kubectl get pod <your pod name> -w whenever any update/change/delete happen to the pod, you will see the update. You can also use watch -n 1 kubectl get pod <your pod name> This will continuously run kubectl get pod .…
Read more ⟶

error: could not lock config file filepath/../.git/config :permission denied


Question i created a folder called "try" in the path /home/bhishan/Copy/try then inside that folder i gave some commands: my commands are follwing: curl -s -O \ http://github-media-downloads.s3.amazonaws.com/osx/git-credential-osxkeychain chmod u+x git-credential-osxkeychain sudo mv git-credential-osxkeychain dirname \which git`` git config –global credential.helper osxkeychain git init git remote add origin https: git remote add origin https: git push origin master ============================== it worked fine but, when i try to delete try folder i cannot delete the folder.…
Read more ⟶