0% found this document useful (0 votes)
13 views5 pages

Devops Ex 1 52 3

The document details a series of Git commands executed in a terminal to clone a repository, create and switch branches, and commit changes to a README file. The user encounters issues with directory navigation and receives warnings about line endings. The final status shows the user is ahead of the origin repository by two commits on the master branch.

Uploaded by

thiruit303
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views5 pages

Devops Ex 1 52 3

The document details a series of Git commands executed in a terminal to clone a repository, create and switch branches, and commit changes to a README file. The user encounters issues with directory navigation and receives warnings about line endings. The final status shows the user is ahead of the origin repository by two commits on the master branch.

Uploaded by

thiruit303
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

Student@WEBLAB-30 MINGW64 ~/JavaProgram (master)

$ git clone https://github.com/Swetha05s/test.git SampleRepo

Cloning into 'SampleRepo'...

remote: Enumerating objects: 6, done.

remote: Counting objects: 100% (6/6), done.

remote: Compressing objects: 100% (5/5), done.

remote: Total 6 (delta 0), reused 6 (delta 0), pack-reused 0 (from 0)

Receiving objects: 100% (6/6), done.

Student@WEBLAB-30 MINGW64 ~/JavaProgram (master)

$ cd sample

bash: cd: sample: No such file or directory

Student@WEBLAB-30 MINGW64 ~/JavaProgram (master)

$ cd sampleRepo

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git status

On branch master

Your branch is up to date with 'origin/master'.

nothing to commit, working tree clean

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git commit -m "message"

On branch master

Your branch is up to date with 'origin/master'.


nothing to commit, working tree clean

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ vi README.txt

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git init

Reinitialized existing Git repository in C:/Users/Student/JavaProgram/SampleRepo

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git add README.txt

warning: in the working copy of 'README.txt', LF will be replaced by CRLF the ne

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git commit -m "Commit 1"

[master a6a4b0f] Commit 1

1 file changed, 2 insertions(+)

create mode 100644 README.txt

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ vi README.txt

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git status

On branch master

Your branch is ahead of 'origin/master' by 1 commit.


(use "git push" to publish your local commits)

Changes not staged for commit:

(use "git add <file>..." to update what will be committed)

(use "git restore <file>..." to discard changes in working directory)

modified: README.txt

no changes added to commit (use "git add" and/or "git commit -a")

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git add README.txt

warning: in the working copy of 'README.txt', LF will be replaced by CRLF the ne

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git commit -m "Commit 2"

[master 9567533] Commit 2

1 file changed, 1 insertion(+)

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git log --oneline

9567533 (HEAD -> master) Commit 2

a6a4b0f Commit 1

ecb00d0 (origin/master, origin/HEAD) Second commit

19be734 First commit

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git branch level


Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git checkout level

Switched to branch 'level'

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (level)

$ git status

On branch level

nothing to commit, working tree clean

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (level)

$ git commit -m "Commit 3"

On branch level

nothing to commit, working tree clean

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (level)

$ git checkout master

Switched to branch 'master'

Your branch is ahead of 'origin/master' by 2 commits.

(use "git push" to publish your local commits)

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git status

On branch master

Your branch is ahead of 'origin/master' by 2 commits.

(use "git push" to publish your local commits)


nothing to commit, working tree clean

Student@WEBLAB-30 MINGW64 ~/JavaProgram/sampleRepo (master)

$ git log --oneline

9567533 (HEAD -> master, level) Commit 2

a6a4b0f Commit 1

ecb00d0 (origin/master, origin/HEAD) Second commit

19be734 First commit

You might also like