There are various package that does this job but we will talk about `tar` that simply zip and uzip files and folders. This small article will show you how to zip and unzip with command using terminal.
To zip files
tar -czvf zip_file_name.tar.gz -C ./dist...
Read More ⟶
We all have heard about codepipeline which simply triggered by a source commit and start a pipeline to build application then deploy automatically to ec2 servers. Upload files to aws ec2. Well this article is not about code pipeline but a simple script that will make...
Read More ⟶
First of all, we need to find out the process id also known as PID of the running process on a specific port. For example, a process is running on port 3000. To find its process id, execute:
lsof -t -i:4200
63562
Now you have the PID '63562' of the process...
Read More ⟶
When injected, HttpBackend dispatches requests directly to the backend, without going through the interceptor chain.
import {HttpBackend, HttpClient} from '@angular/common/http';
import {Injectable} from '@angular/core';
@Injectable({
providedIn:...
Read More ⟶
Search the path of actual installed packged detination. After that copy and run like below command.
which npm
which node
which pm2
sudo ln -s /home/ec2-user/.nvm/versions/node/v16.15.1/bin/npm
sudo ln -s /home/ec2-user/.nvm/versions/node/v16.15.1/bin/node
sudo...
Read More ⟶
This article will show you how to use Angular Date pipe in component ts file.
To achieve the same we need to import `DatePipe` exported function from angular core modules.
import { DatePipe } from '@angular/common';
transform() {
return new...
Read More ⟶
This error generally comes when you upgrade your angular fire and firebase to the latest version.
data['id']=this.createId();
For the new Firebase 9 you need to do the following change.
...
Read More ⟶
Revert last commit in GIT
git reset --soft HEAD~1
--soft will not remove your uncommited code. Again if you replace the same with --hard it is going to replace all the uncommited code in your local
git reset --hard...
Read More ⟶
Here we will show you how to track all remote branches in GIT and get them all at once in your local.
Below is the demo of a git where there are several branches and each branches there are some code.
https://github.com/Santoshah/firebase-auth
To get...
Read More ⟶
Three modes of SVG
Object
embeded srcobject data=""iframe src=""
Image
img srcbackground : url()
Inline
svg path {stroke-dasharray: 5, 2;stroke-dashoffset :...
Read More ⟶