Introduction to GitHub branching in 10 commands: 1. git clone [repo_url] 2. git branch [-r] [-a] 3. git branch --set-upstream-to 4. git pull 5. git checkout [-b] [branch_name] 6. git push origin HEAD:[branch_name] 7. git switch -c [branch_name] 8. git log 9. git clone --branch [branch_name] [repo_url] 10. git push --set-upstream origin [branch_name] Why concept of branching using an image: Now the commands:1. INITIAL SETUP USING "git clone"
CMD>git clone https://github.com/ashishjain1547/repo_for_testing.git Cloning into 'repo_for_testing'... Logon failed, use ctrl+c to cancel basic credential prompt. Username for 'https://github.com': aj@gmail.com Password for 'https://aj@gmail.com@github.com': remote: Enumerating objects: 8, done. remote: Counting objects: 100% (8/8), done. remote: Compressing objects: 100% (5/5), done. remote: Total 8 (delta 1), reused 4 (delta 1), pack-reused 0 Unpacking objects: 100% (8/8), 4.98 KiB | 10.00 KiB/s, done. CMD>dir /b repo_for_testing CMD>cd repo_for_testing CMD\repo_for_testing>dir /b .gitignore LICENSE newFile.txt README.md CMD\repo_for_testing> type newFile.txt NEWFILE2. LIST ALL THE BRANCHES
git branch: shows the local branches git branch -r: shows the remote branches git branch -a: shows all the branches (both local and remote) ~\aj> git clone https://github.com/ashishjain1547/repo_for_testing.git Cloning into 'repo_for_testing'... remote: Enumerating objects: 14, done. remote: Counting objects: 100% (14/14), done. remote: Compressing objects: 100% (8/8), done. remote: Total 14 (delta 4), reused 8 (delta 2), pack-reused 0 Unpacking objects: 100% (14/14), 5.41 KiB | 5.00 KiB/s, done. ~\aj> cd repo_for_testing ~\aj\repo_for_testing> git branch * main ~\aj\repo_for_testing> git branch -r origin/HEAD -> origin/main origin/main origin/test_branch ~\aj\repo_for_testing> git branch -a * main remotes/origin/HEAD -> origin/main remotes/origin/main remotes/origin/test_branch ~\aj\repo_for_testing> git checkout -b test_branch Switched to a new branch 'test_branch' Note: If you already have a branch named "test_branch" in your local, then you would not pass the argument "-b". ~\aj\repo_for_testing> git branch main * test_branch ~\aj\repo_for_testing> git branch -r origin/HEAD -> origin/main origin/main origin/test_branch Note: we would not see any changes in the remote branches from "git checkout" command. ~\aj\repo_for_testing> git branch -a main * test_branch remotes/origin/HEAD -> origin/main remotes/origin/main remotes/origin/test_branch3. SUPPOSE YOUR NEW REMOTE BRANCH IS NOT VISIBLE IN CMD USING "git branch -r", THEN TO LOAD NEW REMOTE BRANCH TO SHOW UP IN AN EXISTING LOCAL REPO, DO A 'GIT PULL'
CMD\repo_for_testing> git branch -r origin/HEAD -> origin/main origin/main CMD\repo_for_testing> git pull From https://github.com/ashishjain1547/repo_for_testing * [new branch] test_branch -> origin/test_branch Already up to date. CMD\repo_for_testing> git branch -r origin/HEAD -> origin/main origin/main origin/test_branch4. CREATING A NEW LOCAL BRANCH 'test_branch', SETTING UPSTREAM BRANCH FOR IT AND ADDING A NEW FILE IN IT
~\aj> git clone https://github.com/ashishjain1547/repo_for_testing.git Cloning into 'repo_for_testing'... remote: Enumerating objects: 19, done. remote: Counting objects: 100% (19/19), done. remote: Compressing objects: 100% (11/11), done. remote: Total 19 (delta 6), reused 12 (delta 3), pack-reused 0 Unpacking objects: 100% (19/19), 5.92 KiB | 6.00 KiB/s, done. ~\aj> cd repo_for_testing ~\aj\repo_for_testing>git branch * main ~\aj\repo_for_testing> git branch -r origin/HEAD -> origin/main origin/main origin/test_branch ~\aj\repo_for_testing> git branch -a * main remotes/origin/HEAD -> origin/main remotes/origin/main remotes/origin/test_branch 'git checkout -b test_branch' CREATES A NEW LOCAL BRANCH NAMED 'test_branch' BECAUSE OF THE ARGUMENT '-b' ~\aj\repo_for_testing> git checkout -b test_branch Switched to a new branch 'test_branch' ~\aj\repo_for_testing>git branch main * test_branch ~\aj\repo_for_testing>git branch -r origin/HEAD -> origin/main origin/main origin/test_branch ~\aj\repo_for_testing> git branch -a main * test_branch remotes/origin/HEAD -> origin/main remotes/origin/main remotes/origin/test_branch ~\aj\repo_for_testing> dir Volume in drive C is Windows Volume Serial Number is 8139-90C0 Directory of ~\aj\repo_for_testing 07/14/2021 04:06 PM DIR> . 07/14/2021 04:06 PM DIR> .. 07/14/2021 04:06 PM 368 .gitignore 07/14/2021 04:06 PM 11,558 LICENSE 07/14/2021 04:06 PM 11 newFile.txt 07/14/2021 04:06 PM 38 README.md 07/14/2021 04:06 PM 23 test_file_20210528.txt 5 File(s) 11,998 bytes 2 Dir(s) 62,644,645,888 bytes free ~\aj\repo_for_testing> git branch --set-upstream-to=origin/test_branch test_branch Branch 'test_branch' set up to track remote branch 'test_branch' from 'origin'. ~\aj\repo_for_testing> git pull Updating daa4600..82c204f Fast-forward 20210528_test_branch.txt | 1 + 202107141543.txt | 1 + 2 files changed, 2 insertions(+) create mode 100644 20210528_test_branch.txt create mode 100644 202107141543.txt ~\aj\repo_for_testing> echo "202107141608" > 202107141608.txt ~\aj\repo_for_testing> dir Volume in drive C is Windows Volume Serial Number is 8139-90C0 Directory of ~\aj\repo_for_testing 07/14/2021 04:08 PM DIR> . 07/14/2021 04:08 PM DIR> .. 07/14/2021 04:06 PM 368 .gitignore 07/14/2021 04:08 PM 30 20210528_test_branch.txt 07/14/2021 04:08 PM 17 202107141543.txt 07/14/2021 04:08 PM 17 202107141608.txt 07/14/2021 04:06 PM 11,558 LICENSE 07/14/2021 04:06 PM 11 newFile.txt 07/14/2021 04:06 PM 38 README.md 07/14/2021 04:06 PM 23 test_file_20210528.txt 8 File(s) 12,062 bytes 2 Dir(s) 62,644,277,248 bytes free ~\aj\repo_for_testing>git status On branch test_branch Your branch is up to date with 'origin/test_branch'. Untracked files: (use "git add <file>..." to include in what will be committed) 202107141608.txt nothing added to commit but untracked files present (use "git add" to track) ~\aj\repo_for_testing> git add -A ~\aj\repo_for_testing> git commit -m "#" [test_branch 9017804] # 1 file changed, 1 insertion(+) create mode 100644 202107141608.txt ~\aj\repo_for_testing> git push Enumerating objects: 4, done. Counting objects: 100% (4/4), done. Delta compression using up to 4 threads Compressing objects: 100% (2/2), done. Writing objects: 100% (3/3), 284 bytes | 142.00 KiB/s, done. Total 3 (delta 1), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (1/1), completed with 1 local object. To https://github.com/ashishjain1547/repo_for_testing.git 82c204f..9017804 test_branch -> test_branch ~\aj\repo_for_testing> Note: Now, you can go to GitHub.com and create a pull request, then merge "test_branch" with "main" branch.5. SWITCHING TO THE NEW BRANCH
CMD\repo_for_testing> git checkout origin/test_branch Note: switching to 'origin/test_branch'. You are in 'detached HEAD' state. You can look around, make experimental changes and commit them, and you can discard any commits you make in this state without impacting any branches by switching back to a branch. If you want to create a new branch to retain commits you create, you may do so (now or later) by using -c with the switch command. Example: git switch -c [new-branch-name] Or undo this operation with: git switch - Turn off this advice by setting config variable advice.detachedHead to false HEAD is now at 5b934da cmt 1909 CMD\repo_for_testing>git branch * (HEAD detached at origin/test_branch) main ~ ~ ~ Use the '-b' argument to also attach the HEAD to new branch. CMD\repo_for_testing> git checkout -b origin/test_branch Switched to a new branch 'origin/test_branch' CMD\repo_for_testing> git branch main * origin/test_branch 6. ADDING A FILE TO THE NEW BRANCH CMD\repo_for_testing> echo "20210528 into test_branch" > "20210528_test_branch.txt" CMD\repo_for_testing> dir /b .gitignore 20210528_test_branch.txt LICENSE newFile.txt README.md CMD\repo_for_testing> git status HEAD detached at origin/test_branch Untracked files: (use "git add [file]..." to include in what will be committed) 20210528_test_branch.txt nothing added to commit but untracked files present (use "git add" to track) CMD\repo_for_testing> git add -A CMD\repo_for_testing> git commit -m "0303" [detached HEAD 03e190f] 0303 1 file changed, 1 insertion(+) create mode 100644 20210528_test_branch.txt CMD\repo_for_testing>git push fatal: You are not currently on a branch. To push the history leading to the current (detached HEAD) state now, use git push origin HEAD:[name-of-remote-branch] CMD\repo_for_testing> git push origin HEAD:test_branch Enumerating objects: 4, done. Counting objects: 100% (4/4), done. Delta compression using up to 4 threads Compressing objects: 100% (2/2), done. Writing objects: 100% (3/3), 306 bytes | 306.00 KiB/s, done. Total 3 (delta 1), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (1/1), completed with 1 local object. To https://github.com/aj/repo_for_testing.git 5b934da..03e190f HEAD -> test_branch7. CHECKING REPOSITORY STATUS USING 'GIT LOG'
CMD\repo_for_testing> git log In the logs below, "HEAD" is detached. commit 03e190f8810c9335613cc2c534914e666c04eeeb (HEAD, origin/test_branch) Author: unknown [abc@xyz.com] Date: Fri May 28 03:03:23 2021 +0530 0303 commit 5b934dac6c399f06275feab5b4a91fa8063e092b (origin/main, origin/HEAD, main) Author: Admin on Ubuntu [admin@master.com] Date: Wed Mar 17 19:09:57 2021 +0530 cmt 1909 commit 974a71b3df68140ebbc3b4775201b39c500aa589 Author: aj [abc@xyz.com] Date: Wed Mar 17 01:32:16 2021 +0530 Initial commit Fixing the detached HEAD: CMD\repo_for_testing>git switch -c origin/test_branch Switched to a new branch 'origin/test_branch' CMD\repo_for_testing>git branch main * origin/test_branch Now the HEAD is pointing to the current branch: CMD\repo_for_testing> git log commit 03e190f8810c9335613cc2c534914e666c04eeeb (HEAD -> origin/test_branch, origin/test_branch) Author: unknown [abc@xyz.com] Date: Fri May 28 03:03:23 2021 +0530 0303 commit 5b934dac6c399f06275feab5b4a91fa8063e092b (origin/main, origin/HEAD, main) Author: Admin on Ubuntu [admin@master.com] Date: Wed Mar 17 19:09:57 2021 +0530 cmt 1909 commit 974a71b3df68140ebbc3b4775201b39c500aa589 Author: aj [abc@xyz.com] Date: Wed Mar 17 01:32:16 2021 +0530 Initial commit8. USING 'GIT CLONE' TO CLONE A BRANCH
CMD\ws_branches\(2)> git clone --branch test_branch https://github.com/aj/repo_for_testing.git Cloning into 'repo_for_testing'... remote: Enumerating objects: 11, done. remote: Counting objects: 100% (11/11), done. remote: Compressing objects: 100% (6/6), done. remote: Total 11 (delta 2), reused 7 (delta 2), pack-reused 0 Unpacking objects: 100% (11/11), 5.23 KiB | 3.00 KiB/s, done. CMD\ws_branches\(2)>cd repo_for_testing CMD\ws_branches\(2)\repo_for_testing>git branch * test_branch CMD\ws_branches\(2)\repo_for_testing>dir /b .gitignore 20210528_test_branch.txt LICENSE newFile.txt README.md9. NOW WE ADD A NEW FILE TO THE 'main' BRANCH
~\ws_branches\(3) main branch> git clone https://github.com/aj/repo_for_testing.git Cloning into 'repo_for_testing'... remote: Enumerating objects: 11, done. remote: Counting objects: 100% (11/11), done. remote: Compressing objects: 100% (6/6), done. remote: Total 11 (delta 2), reused 7 (delta 2), pack-reused 0 Unpacking objects: 100% (11/11), 5.23 KiB | 3.00 KiB/s, done. ~\ws_branches\(3) main branch>cd repo_for_testing ~\ws_branches\(3) main branch\repo_for_testing>dir /b .gitignore LICENSE newFile.txt README.md ~\ws_branches\(3) main branch\repo_for_testing>echo "test_file_20210528" > "test_file_20210528.txt" ~\ws_branches\(3) main branch\repo_for_testing>dir /b .gitignore LICENSE newFile.txt README.md test_file_20210528.txt ~\ws_branches\(3) main branch\repo_for_testing>git add -A ~\ws_branches\(3) main branch\repo_for_testing>git commit -m "0357" [main daa4600] 0357 1 file changed, 1 insertion(+) create mode 100644 test_file_20210528.txt ~\ws_branches\(3) main branch\repo_for_testing>git push Enumerating objects: 4, done. Counting objects: 100% (4/4), done. Delta compression using up to 4 threads Compressing objects: 100% (2/2), done. Writing objects: 100% (3/3), 298 bytes | 298.00 KiB/s, done. Total 3 (delta 1), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (1/1), completed with 1 local object. To https://github.com/aj/repo_for_testing.git 5b934da..daa4600 main -> main ~\ws_branches\(3) main branch\repo_for_testing>10. NEXT, WE GET THAT NEW FILE INTO OUR 'test_branch'
~\ws_branches\(2) test_branch\repo_for_testing>git branch * test_branch ~\ws_branches\(2) test_branch\repo_for_testing>git fetch remote: Enumerating objects: 4, done. remote: Counting objects: 100% (4/4), done. remote: Compressing objects: 100% (1/1), done. remote: Total 3 (delta 1), reused 3 (delta 1), pack-reused 0 Unpacking objects: 100% (3/3), 278 bytes | 2.00 KiB/s, done. From https://github.com/aj/repo_for_testing 5b934da..daa4600 main -> origin/main ~\ws_branches\(2) test_branch\repo_for_testing>dir /b .gitignore 20210528_test_branch.txt LICENSE newFile.txt README.md ~\ws_branches\(2) test_branch\repo_for_testing>git branch -r origin/HEAD -> origin/main origin/main origin/test_branch ~\ws_branches\(2) test_branch\repo_for_testing> git checkout origin/main Note: switching to 'origin/main'. You are in 'detached HEAD' state. You can look around, make experimental changes and commit them, and you can discard any commits you make in this state without impacting any branches by switching back to a branch. If you want to create a new branch to retain commits you create, you may do so (now or later) by using -c with the switch command. Example: git switch -c <new-branch-name> Or undo this operation with: git switch - Turn off this advice by setting config variable advice.detachedHead to false HEAD is now at daa4600 0357 ~\ws_branches\(2) test_branch\repo_for_testing>git switch -c origin/main Switched to a new branch 'origin/main' ~\ws_branches\(2) test_branch\repo_for_testing>git branch * origin/main test_branch ~\ws_branches\(2) test_branch\repo_for_testing>dir /b .gitignore LICENSE newFile.txt README.md test_file_20210528.txt ~\ws_branches\(2) test_branch\repo_for_testing> git pull There is no tracking information for the current branch. Please specify which branch you want to merge with. See git-pull(1) for details. git pull <remote> <branch> If you wish to set tracking information for this branch you can do so with: git branch --set-upstream-to=origin/<branch> origin/main ~\ws_branches\(2) test_branch\repo_for_testing>git pull https://github.com/aj/repo_for_testing.git origin/main fatal: couldn't find remote ref origin/main ~\ws_branches\(2) test_branch\repo_for_testing>git branch --set-upstream-to=origin/test_branch origin/main Branch 'origin/main' set up to track remote branch 'test_branch' from 'origin'. ~\ws_branches\(2) test_branch\repo_for_testing>git pull Merge made by the 'recursive' strategy. 20210528_test_branch.txt | 1 + 1 file changed, 1 insertion(+) create mode 100644 20210528_test_branch.txt ~\ws_branches\(2) test_branch\repo_for_testing>dir /b .gitignore 20210528_test_branch.txt LICENSE newFile.txt README.md test_file_20210528.txt ~\ws_branches\(2) test_branch\repo_for_testing>git checkout origin/test_branch Note: switching to 'origin/test_branch'. You are in 'detached HEAD' state. You can look around, make experimental changes and commit them, and you can discard any commits you make in this state without impacting any branches by switching back to a branch. If you want to create a new branch to retain commits you create, you may do so (now or later) by using -c with the switch command. Example: git switch -c <new-branch-name> Or undo this operation with: git switch - Turn off this advice by setting config variable advice.detachedHead to false HEAD is now at 03e190f 0303 ~\ws_branches\(2) test_branch\repo_for_testing>git switch -c origin/test_branch Switched to a new branch 'origin/test_branch' ~\ws_branches\(2) test_branch\repo_for_testing>dir /b .gitignore 20210528_test_branch.txt LICENSE newFile.txt README.md ~\ws_branches\(2) test_branch\repo_for_testing>git switch -c origin/main fatal: A branch named 'origin/main' already exists. ~\ws_branches\(2) test_branch\repo_for_testing>git merge origin/main warning: refname 'origin/main' is ambiguous. warning: refname 'origin/main' is ambiguous. Updating 03e190f..fca45d6 Fast-forward test_file_20210528.txt | 1 + 1 file changed, 1 insertion(+) create mode 100644 test_file_20210528.txt ~\ws_branches\(2) test_branch\repo_for_testing>git push fatal: The current branch origin/test_branch has no upstream branch. To push the current branch and set the remote as upstream, use git push --set-upstream origin origin/test_branch CMD\ws_branches\(2) test_branch\repo_for_testing>git push --set-upstream origin origin/test_branch This step might have been wrong w.r.t. the input argument above. The command should have been: git push --set-upstream origin test_branch Enumerating objects: 4, done. Counting objects: 100% (4/4), done. Delta compression using up to 4 threads Compressing objects: 100% (2/2), done. Writing objects: 100% (2/2), 354 bytes | 354.00 KiB/s, done. Total 2 (delta 1), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (1/1), completed with 1 local object. remote: remote: Create a pull request for 'origin/test_branch' on GitHub by visiting: remote: https://github.com/aj/repo_for_testing/pull/new/origin/test_branch remote: To https://github.com/aj/repo_for_testing.git * [new branch] origin/test_branch -> origin/test_branch Branch 'origin/test_branch' set up to track remote branch 'origin/test_branch' from 'origin'. ~\ws_branches\(2) test_branch\repo_for_testing>dir /b .gitignore 20210528_test_branch.txt LICENSE newFile.txt README.md test_file_20210528.txt ~\ws_branches\(2) test_branch\repo_for_testing>git branch origin/main * origin/test_branch test_branch ~\ws_branches\(2) test_branch\repo_for_testing>git branch -r origin/HEAD -> remotes/origin/main origin/main origin/origin/test_branch origin/test_branch ~\ws_branches\(2) test_branch\repo_for_testing>git log commit fca45d643326fb5d88d70c0cf699f7032118df4b (HEAD -> origin/test_branch, origin/origin/test_branch, origin/main) Merge: daa4600 03e190f Author: unknown <aj@gmail.com> Date: Fri May 28 04:02:07 2021 +0530 Merge branch 'test_branch' of https://github.com/aj/repo_for_testing into origin/main commit daa46003a895e4b33577e3c248977334620e3558 (origin/main, origin/HEAD) Author: unknown <aj@gmail.com> Date: Fri May 28 03:57:24 2021 +0530 0357 commit 03e190f8810c9335613cc2c534914e666c04eeeb (origin/test_branch, test_branch) Author: unknown <aj@gmail.com> Date: Fri May 28 03:03:23 2021 +0530 0303 commit 5b934dac6c399f06275feab5b4a91fa8063e092b Author: Admin on Ubuntu <administrator@master.com> Date: Wed Mar 17 19:09:57 2021 +0530 cmt 1909 commit 974a71b3df68140ebbc3b4775201b39c500aa589 Author: aj <aj@gmail.com> Date: Wed Mar 17 01:32:16 2021 +0530 Initial commit ~\ws_branches\(2) test_branch\repo_for_testing>
Thursday, May 27, 2021
Introduction to GitHub branching in 10 commands
Wednesday, May 26, 2021
20210416 - Monitoring effects of Trinicalm Plus
Index of Journals
20210416 2130: 1 pill of Trinicalm Plus ingested with water. SALT COMPOSITION Trifluoperazine (5mg) + Trihexyphenidyl (2mg) [Read the end notes] 2137: How do I feel? Am self-conscious and anticipating the influence of this pill. 2150: feeling slight influence of the pill. Cannot label the feeling. 2153: One thing the medicine does is that it stops your train of thoughts and draws your attention towards it's influence on you. 2155: The influence of this pill is that it leaves you emotionless in a way. You don't get excited on seeing a person to the point that you would have no qualms as you would decide to walk past him or her, the person you saw. 2201: Now if you would do anything like eating food or working out or writing code, you would be doing it solely for the sake of doing it. You are so calm and placid. 2213: One important thing to note is: I was neither anxious nor unwell the time I took the pill. I took the pill for the sole purpose of checking it's influence and logging it. 2218: If you would lie down to sleep while under the influence of this medicine, you would not be able to catch sleep either as you are in a sort of emotionless, placid and self-conscious state. 2221: You don't have thoughts that will make you happy or sad. 2241: If you take this pill, you might complain that you don't feel happy, that you are enjoying doing things that you would have otherwise enjoyed doing. Such as eating food or your favourite dish. I just finished having dinner. 2248: If you get the thoughts about people with you might have feelings of revenge or people who might have been hostile to you, chances are that you might get the idea that the thought of those people is supposed to make you unhappy or upset but it might not drive you into taking any action or be excited about. 2253: To be very frank, I was thinking of people such as Veena Rally, Tanuja Nautiyal and Hardik Vashishth before writing at 2248. 2309: Time to sleep.End Notes
Drug 1: Trifluoperazine HCL Common Brand(S): Stelazine Generic Name(S): trifluoperazine Ref 1.1: webmd This medication is used to treat certain mental/mood disorders (such as schizophrenia, psychotic disorders). Trifluoperazine helps you to think more clearly, feel less nervous, and take part in everyday life. It can reduce aggressive behavior and the desire to hurt yourself/others. It may also help to decrease hallucinations (hearing/seeing things that are not there). Trifluoperazine is a psychiatric medication that belongs to the class of drugs called phenothiazine antipsychotics. It works by helping to restore the balance of certain natural substances in the brain.This medication has also been used for the short-term treatment of anxiety. However, there are safer drugs to treat anxiety that should be used first before trifluoperazine. Ref 1.2: Wikipedia Trifluoperazine, sold under a number of brand names, is a typical antipsychotic primarily used to treat schizophrenia. It may also be used short term in those with generalized anxiety disorder but is less preferred to benzodiazepines. It is of the phenothiazine chemical class. Drug 2: Trihexyphenidyl HCL Common Brand(S): Artane Generic Name(S): trihexyphenidyl Ref 2.1: webmd Trihexyphenidyl is used to treat symptoms of Parkinson's disease or involuntary movements due to the side effects of certain psychiatric drugs (antipsychotics such as chlorpromazine/haloperidol). Trihexyphenidyl belongs to a class of medication called anticholinergics that work by blocking a certain natural substance (acetylcholine). This helps decrease muscle stiffness, sweating, and the production of saliva, and helps improve walking ability in people with Parkinson's disease.Anticholinergics can stop severe muscle spasms of the back, neck, and eyes that are sometimes caused by psychiatric drugs. It can also decrease other side effects such as muscle stiffness/rigidity (extrapyramidal signs-EPS). It is not helpful in treating movement problems caused by tardive dyskinesia and may worsen them. Ref 2.2: Wikipedia Trihexyphenidyl, also known as benzhexol and trihex, is an antiparkinsonian agent of the antimuscarinic class. It was approved by the FDA for the treatment of Parkinson's in 2003. Tags: Journal,Technology,Science,Behavioral Science,Medicine,Emotional Intelligence,Psychology,
Types of Massages at Tenzin Spa as of Apr-2021
Index of Journals
1. Balinese (AKA Balimese)
15 mins: Dry
45 mins: Oil
Then: Steam and Shower for 15 mins
Or Jacuzzi for 15 mins
Oil: Olive Oil
2. Thai Massage
% Full dry massage
% Mainly stretching
% And handling of pressure points
3. Aroma Massage or Fragrance Massage
% 15 mins: Dry
% 45 mins: Oil
% Both with light pressure.
After that (Steam + Shower) or Jacuzzi for 15 mins.
Oil: Lemongrass Oil
Note: Olive oil is edible while Lemongrass oil is not.
Olive oil is a healthy fat that contains anti-inflammatory compounds. Drinking it regularly may benefit your heart, bone, and digestive health and help stabilize your blood sugar levels.
4. Deep Tissue
% 15 mins: Dry
% 45 mins: Oil
% Both with deep pressure.
% Very good for muscles, joints and stiff tissues.
% After that (Steam + Shower) or Jacuzzi for 15 mins.
5. Hot Stone Massage
Good for joint parts and pain relief.
6. Swedish Massage
Good for:
% Relaxation
% Stress relief
% Boosting immune system
% Blood circulation
7. Cream Massage
In summers, some clients prefer cream as the oil does not suite them.
The cream has been imported from Bangkok.
8. Body Polishing
Good for:
% scrubbing
% tanning
% removing dead skin cells.
9. Facial
% Good for removing black heads.
% The process of removing black heads can be painful.
No work, no food. -- Sonam Shodon
Tags: Journal,Science,Psychology,
Tete-a-tete with Airtel Store Executive (May 2021)
Index of Journals
Tete-a-tete with Airtel Store Executive (Johnson in Chandigarh in May 2021)
1. About the bill:
Bill will be shown in "Airtel Thanks" app and will also be sent on mail.
2. How do I check my data usage?
"My Airtel" or "Airtel Thanks" app.
3. Debt on Airtel:
AGR Dues: AGR stands for Adjust Gross Revenue.
According to him:
Airtel and Jio have cleared their debts.
Vodafone-Idea is still left.
4. Circles of Airtel.
He did not understand the questions and I was not aware of using the correct Telecommunication jargon for rephrasing my question.
His answer: IT park in Chandigarh, Sector 17 Chandigarh, and other sectors such as 22 and 23 in Chandigarh.
5. His reporting manager's number
Anita Singh
Phn: +91 98150 49795
Title: Store Manager, Sec 15, Chandigarh
6. Airtel Payments Bank:
6.1. For recharge
6.2. Bill payment
6.3. Insurance
6.4. To onboard, do KYC.
6.5. Purely digital bank.
7. Other Airtel services and businesses:
7.1 Postpaid
7.2 Prepaid
7.3 Broadband
7.4 DTH (Digital TV)
7.5 Banking
8. Other Notes
8.1 When Anil Ambani's company Reliance Communications closed, crores of phone numbers were not ported and were unregistered.
8.2 Vi is now bringing 'You Broadband' but Airtel's wiring has already been done and Vi is starting now.
8.3 Network sharing: for roaming in places such as Himachal Pradesh, Airtel has partenership with BSNL and all for network sharing.
8.4 At an Airtel Store: Payment process is completely digital.
8.5 At a Distributor or Vendor Store: Payment bill is hand-written. Vendor stores are only for recharge, bill payment and SIM allotment.
Dated: 20210527
Tags: Journal,Indian Politics,Investment,Management,
Money Spent in Finding a Life Partner till May 2021 and Tips from Anil Dahiya
Index of Journals
Dating: 3000 INR (Angela Chandel, Nishtha Rajput, Mansi Jain)
Tinder: 4400 INR
Shaadi.com in 2019: 4000 INR
Shaadi.com in 2020: 13000 INR
Total: 3000 + 4400 + 4000 + 13000 = 24,400 INR
- - - - -
What I Look For In a Girl
1. Whether she holds a job or not. Whether she is working or not.
2. She should be perfect in English.
3. She should agree to sign prenuptial agreement.
- - - - -
Anil Dahiya's Advice on Prenuptial Agreement
1. Prenuptial agreement is not feasible. (Anil was not aware the prenuptial agreement does not even exist in India with the exception of Goa.)
2. His advice to me: "If you will discuss it with her, she will start doubting you."
3. "It maybe right for you but it may not be right thing for her."
- - - - -
What Anil Suggests I Should Find Out
1. How is the girl's family?
2. Thought process of the girl.
3. The basic background check. Past relationships, drinking or smoking habits, etc.
- - - - -
His Advice About Going Abroad
India will need a lot of time to develop due to its lame policies such as the one about "Age Limit On Entering The PSUs". India has an age limit for who can apply for a job in a PSU (Public Sector Undertaking).
It is not like that in other countries.
Dated: 20210326
Tags: Journal,Indian Politics,Politics,Management
Sunday, May 23, 2021
Python (2) String and related packages [20210523]
We would begin with a line about Python String from the book "Pg 191, Learning Python (O'Reilly, 5e)": Strictly speaking, Python strings are categorized as immutable sequences, meaning that the characters they contain have a left-to-right positional order and that they cannot be changed in place. In fact, strings are the first representative of the larger class of objects called sequences that we will study here. Pay special attention to the sequence operations introduced in this post, because they will work the same on other sequence types we’ll explore later, such as lists and tuples. Table 7-1. Common string literals and operations
Operation | Interpretation |
S = '' | Empty string |
S = "spam's" | Double quotes, same as single |
S = 's\np\ta\x00m' | Escape sequences |
S = """...multiline...""" | Triple-quoted block strings |
S = r'\temp\spam' | Raw strings (no escapes) print(S) # \temp\spam |
B = b'sp\xc4m' | Byte strings in 2.6, 2.7, and 3.X print(B) # b'sp\xc4m' |
U = u'sp\u00c4m' | Unicode strings in 2.X and 3.3+ print(U) # spÄm |
S1 + S2 | Concatenate |
S * 3 | repeat |
S[i] | Index |
S[i:j] | slice |
len(S) | length |
"a %s parrot" % 'kind' | String formatting expression print("a %s parrot" % 'kind') # a kind parrot |
"a {0} parrot".format('kind') | String formatting method in 2.6, 2.7, and 3.X |
S.find('pa') | String methods (see ahead for all 43): search print('a parrot'.find('pa')) # 2 |
S.rstrip() | remove whitespace from end print("!" + " okay ".rstrip() + "!") # ! okay! |
S.strip() | remove whitespace from beginning and end print("!" + " okay ".strip() + "!") # !okay! |
S.replace('pa', 'xx') | replacement print("parrot".replace('pa', 'xx')) # xxrrot |
S.split(',') | split on delimiter |
S.isdigit() | content test |
S.lower() S.upper() | case conversion print("Parrot".lower()) # parrot print("parrot".upper()) # PARROT |
S.endswith('spam') | end test print("is this yours".endswith("yours")) # True print("my parrot".startswith("my")) # True |
'spam'.join(strlist) | delimiter join |
S.encode('latin-1') | Unicode encoding |
B.decode('utf8') | Unicode decoding, etc. |
for x in S: print(x) | Iteration |
'spam' in S | membership |
[c * 2 for c in S] | list comprehension to create a new list |
map(ord, S) | map(ord, "hello") # [104, 101, 108, 108, 111] map(lambda x: 10*x, [1,2,3,4]) # [10, 20, 30, 40] |
re.match('sp(.*)am', line) | Pattern matching: library module |
Now Some Hands-On
# Picking the fifth character from a string str_1 = "Hi, I am Ashish!" str_1[4] 'I' # Picking characters from fifth to tenth str_1[4:10] 'I am A' # Print the length of the string print(len(str_1)) print(len(str_1[4:10])) 16 6 # Print every second character in the string str_1[0::2] 'H,Ia sih' # When you give negative number for indexing, it starts traversing the string from the right: print(str_1[-1]) print(str_1[-2]) print(str_1[-5 : -1]) print(str_1[-5 :]) ! h hish hish! When you are giving a range for indexing to a string, the first number should be smaller than the second, or nothing comes out: print("str_1[-1 : -5]: ", str_1[-1 : -5], "<-") str_1[-1 : -5]: <- # Reverse a string print("-->", str_1[len(str_1) : 0]) print("-->", str_1[6 : 0]) print() """Here it skips the first character because that's how indexing works. It excludes the last indexing number specified.""" print("-->", str_1[len(str_1) : 0 : -1]) print("-->", str_1[len(str_1) : 0 : -1]) print() print("-->", str_1[len(str_1) : : -1]) print("-->", str_1[ : : -1]) print() print("-->", str_1[len(str_1)+1 : : -1]) print("-->", str_1[0 : len(str_1)+1]) --> --> --> !hsihsA ma I ,i --> !hsihsA ma I ,i --> !hsihsA ma I ,iH --> !hsihsA ma I ,iH --> !hsihsA ma I ,iH --> Hi, I am Ashish! When you are specifying number for an indexing range, the number can go beyond the actual string length but not when you are picking only a character: print("-->", str_1[len(str_1)+1]) IndexError Traceback (most recent call last) <ipython-input-32-ae4c8bcbdc17> in <module> ---> print("-->", str_1[len(str_1)+1]) IndexError: string index out of range # Check if a string is a palindrome str_2 = "mom" print(str_2 == str_2[::-1]) print(str_1 == str_1[::-1]) True False # Check if two string variables are actually same. Important Note: What we are going to see in this piece of code does not hold true for lists. v1 = str_2 v2 = str_2 v3 = 'mom' print("v1 == v2:", v1 == v2) print("v1 == v3:", v1 == v3) print("v1 is v2:", v1 is v2) print("v1 is v3:", v1 is v3) print("id(v1)", id(v1)) print("id(v3)", id(v3)) v1 == v2: True v1 == v3: True v1 is v2: True v1 is v3: True id(v1) 2053130113968 id(v3) 2053130113968 # Now trying the same thing with lists: animals = ['python','gopher'] more_animals = animals print("animals == more_animals:", animals == more_animals) #=> True print("animals is more_animals:", animals is more_animals) #=> True even_more_animals = ['python','gopher'] print("animals == even_more_animals:", animals == even_more_animals) #=> True print("animals is even_more_animals:", animals is even_more_animals) #=> False print("\nMemory addresses:") print("id(animals)", id(animals)) print("id(more_animals)", id(more_animals)) print("id(even_more_animals)", id(even_more_animals)) animals == more_animals: True animals is more_animals: True animals == even_more_animals: True animals is even_more_animals: False Memory addresses: id(animals) 2053130940992 id(more_animals) 2053130940992 id(even_more_animals) 2053130060928 Checking what happens to a string when replace a character in a string and to a list when we replace an element in it: owner = 'Ashish' pets = ['python', 'gopher'] print("owner:", owner) print("id(owner): ", id(owner)) print("id(pets): ", id(pets)) owner = owner.replace('A', 'X') # Note: we don't have a "replace()" method for Python lists. pets[0] = 'cat' print("owner:", owner) print("id(owner): ", id(owner)) print("id(pets): ", id(pets)) owner = owner.replace('X', 'A') pets[0] = 'python' print("owner:", owner) print("id(owner): ", id(owner)) print("id(pets): ", id(pets)) print("Trivial replacement:") owner = owner.replace('A', 'A') print("owner:", owner) print("id(owner): ", id(owner)) owner: Ashish id(owner): 2287299151536 id(pets): 2287299204096 owner: Xshish id(owner): 2287299080624 id(pets): 2287299204096 owner: Ashish id(owner): 2287298874672 id(pets): 2287299204096 Trivial replacement: owner: Ashish id(owner): 2287298874672 Now the question is: did it actually perform the trivial replace operation in this case or not?Creating Replace For List
# a loop to do the replacement in-place words = ['I', 'like', 'chicken'] for i, word in enumerate(words): if word == 'chicken': words[i] = 'broccoli' print(words) ['I', 'like', 'broccoli'] # a shorter option if there’s always exactly one instance: words = ['I', 'like', 'chicken'] words[words.index('chicken')] = 'broccoli' print(words) ['I', 'like', 'broccoli'] # a list comprehension to create a new list: words = ['I', 'like', 'chicken'] new_words = ['broccoli' if word == 'chicken' else word for word in words] print(new_words) ['I', 'like', 'broccoli'] # any of which can be wrapped up in a function: words = ['I', 'like', 'chicken'] def replaced(sequence, old, new): return (new if x == old else x for x in sequence) new_words = list(replaced(words, 'chicken', 'broccoli')) print(new_words) ['I', 'like', 'broccoli'] #-#-#-#-#-#-#-#-#-#Python's in-built support for String and List
1. reversed() >>> s1 = "Hi, I am Ashish!" >>> ''.join(reversed(s1)) '!hsihsA ma I ,iH' >>> reversed(s1) <reversed object at 0x000001D587048518> >>> list(reversed(s1)) ['!', 'h', 's', 'i', 'h', 's', 'A', ' ', 'm', 'a', ' ', 'I', ' ', ',', 'i', 'H'] >>> str(reversed(s1)) '<reversed object at 0x000001D587048B70>' >>> >>> l1 = ['Ashish', 'Rashmi', 'Smita'] >>> reversed(l1) <list_reverseiterator object at 0x000001D5870702B0> >>> list(reversed(l1)) ['Smita', 'Rashmi', 'Ashish'] >>> 2. sorted() >>> sorted(s1) [' ', ' ', ' ', '!', ',', 'A', 'H', 'I', 'a', 'h', 'h', 'i', 'i', 'm', 's', 's'] >>> >>> sorted(l1) ['Ashish', 'Rashmi', 'Smita'] >>> >>> l2 = ['Rashmi', 'Ashish', 'Smita'] >>> sorted(l2) ['Ashish', 'Rashmi', 'Smita'] >>> 3. len() >>> len(s1) 16 >>> len(l1) 3 >>> Tags: Technology,Python,Anaconda,Natural Language Processing,'Visual Studio Code' Shortcuts
A Tip About Visual Studio Code:
Tip 1:
If press this sequence:
1: "i"
2: "Enter"
This will put <i> in your HTML file.
#-#-#-#-#-#-#-#-#-#
Tip 2:
If you press this sequence:
1: "i."
2: "Enter"
This will put <i class=""> in your HTML file.
#-#-#-#-#-#-#-#-#-#
Tip 3:
If you press this sequence:
1: "i/"
2: "Enter"
This will put only the opening tag in your HTML template, for "i/" it will be: <i>.
#-#-#-#-#-#-#-#-#-#
Tip 4:
If you press this sequence:
1: "i.customClass"
2: "Enter"
This will put <i class="customClass"></i> in HTML template.
#-#-#-#-#-#-#-#-#-#
Tip 5:
If you press this sequence:
1: "i#customID"
2: "Enter"
This will put <i id="customID"></i> in HTML template.
Tags: Technology,Web Development,
Anu's Roka Ceremony (Nov, 2019)
Index of Journals
When I heard of the roka ceremony for Anu, I was like "do we also do that?"My mom called it "rokna" while talking to me and in Western countries, it is called engagement.
Yesterday it was decided that Anu and Tushar would exchange rings in the presence of the elders such as Tushar's tauji and cousins from Aligarh (I could be wrong about the place).
Anu wore a lemon colored saree and Tushar wore a dark green kurta and white pyjamas.
I was resting in my room in my bed due to the high caffeine intake yesterday. All of the required people had assembled in the living room and there were conversations about marriage, mother-in-law daughter-in-law relationship, and all.
A joke I remember from these conversations is from Anil Kumar fufaji. It goes like this:
Secret of mother-in-law and daughter-in-law relationship is that daughter-in-law should daily touch mother-in-law's feet and mother should bless daughter by putting her hand on her head. If either one disobeys this secret, there would be fights.
Before the ceremony actually began or any roka related activity began, there was this period of silence which was not making me feel very comfortable. The way I sat on that chair without hand-rests was by bending forward with shoulders out and looking at my hands. I was restless and I knew that the posture would indicate the same thing to the people.
While writing about that moment I just happen to remember few more such moments of silence with other people at other times that I am going to share here:
1. We were in Amitabh's car. Asmita and myself. Amitabh was driving and we were returning from Elante mall (Sector 17, CHD) I think. It could be that it was some other eating place as we had come out for team outing that day. It was a party that Amitabh gave to the team for no reason as such, just an outing. Now we were going to drop Asmita at her place and there was this silent ride at night in Chandigarh. Then Amitabh broke the silence by saying: "Itna sannaataa kyon hai bhai?"That translates to "why it is so quiet, brother?". This is a famous dialogue from the 1975 Hindi movie Sholay.To respond to Amitabh, I said "people just say things that they want to say without meaning it, or without anyone listening to them and it all goes into air as if it never happened, as if saying it was no different from not saying it." To this Amitabh said, "you are right, we see people these days who are wasting away their lives in partying and drinking and in that alcohol influence they talk endlessly to ruin things not only for themselves but everyone."
2. There was this time when I again with my team but Amitabh was not there and I don't think even entire team was there. We were again at an eating place and it could be the Food Court. I was having this restlessness and temptation to speak and maybe it was also coming out in my body language that Kajal picked up. Seeing this she tells me that it is not mandatory that someone has to speak at all times when people come together. You can be quiet, at rest, at peace too.
3. It was on a call with a friend of mine Jayeta and after talking for 10-15 minutes there came a time when I was silent with her on the phone and then I spoke to ask "does my silence make you uncomfortable because that's how I am at a lot of times with a lot of people on a lot of calls". To this Jayeta replied something like "when two people become comfortable with the silence of each other that phase in the relationship is called "Thairaav". Thairaav is Hindi word for a very abstract and deep concept that I can try to put into English words. You may call it "stability" or "time when even the presence of other person comforts you", or more generally "when things have become slow and stable". Well, those were my three attempts to put the word across you.
~ ~ ~
The silence was also feeling awkward to me because Neelima maasi is a Kindergarten teacher and Priyanka is an HR.
While I write about the day of Roka after almost a year and a half, I would make little sense about the ceremony of roka itself. So what am saying here is absolutely like how I describe it to people. It is a vantage point, a view from my position.
In roka ceremony, the boy and his family are present at the girl's house. The girl's family does a tika to the boy. Tika means putting a mark on the forehead of the person with the crimson. Shape of tika varies if it is on boy or girl. For girl, it is like a circular spot and for boy, after you put a circular spot, you smudge it in the upward direction.
At the time of tika (crimson), there would be people clicking pictures so you would have to pose for them also.
After the tika (crimson), mom and I were to have a picture with the couple. Anu was on Tushar's left and I was on Anu's left. I asked her if I can bring my right arm around her from behind and hold her from the shoulder. She said 'no'.
All now I had to do was sit on the arm-rest, put my hands together with myself, smile and tilt my head in her direction to show some closeness between us.
Due to shortage of time at this moment on 23rd May 2021, I would try to wrap it up in few lines but I might write more if needed.
After the ceremony, we went to Haldiram's place in the Akshardham Temple's Parasvnath mall. There the catering service was not there. Accomodation for all the members of two families was not there. If accomodation could somehow be arraged, it was on separate tables and the manager said that we were not allowed to move the tables.
As for me, I did the catering work of bringing the food from the counter to the people sitting at their tables.
No shame in that. I had been part of Voice of Youth with Employee Relations team at my office and as being part of VoY, we were often required by the HR to help them organize events.
Tags: Journal,Behavioral Science,Emotional Intelligence,
Friday, May 21, 2021
Activating MFA on GitHub and also PAT [May 2021]
Log into GitHub account and follow the screenshots: I1 - Go to Account Security: github.com/settings/security I2 - GitHub MFA using Authenticator App I3 - GitHub asks you to scan a barcode and provide 6-digit code from the Authenticator app I4 - Microsoft Authenticator App (Download Screenshot) I5 - Manage MFA - Recovery Options [URL: github.com/settings/two_factor_authentication/configure ] I6 - Also make sure to set up: Personal Access Tokens [URL: github.com/settings/tokens] Tags: Cloud, Cyber Security, Technology,GitHub,
Subscribe to:
Posts (Atom)