Git init | Initialize a local Git repository The git init command creates a new Git repository in local. This is usually the first command you will run before working on a new project. git …

Last updated 4 years, 4 months ago | 1678 views

Tags:- Git

Git | git status to check the status of the current branch The git status command displays all the necessary information about the working directory and the staging area. git status It displays information like: …

Last updated 4 years, 4 months ago | 1922 views

Tags:- Git

Git | git checkout to Switch branch Git checkout is mostly used for switching from one branch to another. It is also used to check out files and commits. Switch to a branch This command …

Last updated 4 years, 4 months ago | 2005 views

Tags:- Git

Git | Git branch command to create, list, and delete git branch command is used to create a new branch, list all branches, and delete a branch. Branches allow developers to work on the same project …

Last updated 4 years, 4 months ago | 1994 views

Tags:- Git

Git clone | clone git repository Git clone command creates a local copy of the existing source code from a remote repository. git clone ssh://[email protected]/<username>/<repository-name>.git To clone a project from Github:  Click on the green button …

Last updated 4 years, 5 months ago | 1959 views

Tags:- Git

Django | Insert record in database using create() function create() create(**kwargs) Create function create a new object with the given `kwargs`, saving it to the database and returning the created object. It creates an object …

Last updated 4 years, 5 months ago | 1856 views

Tags:- Django

Django | order_by query set, ascending and descending order_by() The order_by function is used to sort the result-set in ascending or descending order. Ascending Order The order_by function sorts the records in ascending order by …

Last updated 4 years, 5 months ago | 2154 views

Tags:- Django

Python | Get the first 5 words from a string This can be done by using the `split()` and `join()` methods >>> massage = 'Today is a sunny day but tomorrow it might rain' >>> …

Last updated 4 years, 5 months ago | 2802 views

Tags:- Python

Django | Overriding the save method The save method is inherited from models.Model class. It is used to override the save method before storing the data in the database. This is used when there is …

Last updated 4 years, 6 months ago | 2384 views

Tags:- Django

Python | Insert and Get data from an index in Elasticsearch To do so we need to import the Elasticsearch package and create an instance of that by providing the host and port. >>> from elasticsearch …

Last updated 4 years, 6 months ago | 7292 views

Tags:- Python Elasticsearch

Python | Program to count the number of words in a string split() and len() method is used to get the number of words in a string. The split() method split a string into a list …

Last updated 4 years, 6 months ago | 1708 views

Tags:- Python

CSS | Gradient Text There are three different CSS properties required to add a gradient overlay to a text. background-image: <gradient> background-clip: text text-fill-color: transparent background-image: <gradient> <gradient> will replace with any gradient style which …

Last updated 4 years, 6 months ago | 1910 views

Tags:- CSS

Python | Ternary Operator python uses an if-else conditional statement in a single line to represent the Ternary Operator. [true] if [expression] else [false]   Let's see an example of Ternary Operator a, b = …

Last updated 4 years, 6 months ago | 2020 views

Tags:- Python

Python | Create and delete an index in Elasticsearch To use the elastic search we need to import the Elasticsearch package >>> from elasticsearch import Elasticsearch now create an object of Elasticsearch search class by providing …

Last updated 4 years, 6 months ago | 2785 views

Tags:- Python Elasticsearch

SQL | Compare timestamp with date only Timestamp holds Date and Time both with 19 characters. To filter table record with the only date parameter can be achieved by SQL DATE() function. Consider the Employee table …

Last updated 5 years, 1 month ago | 2092 views

Tags:- SQL MySQL