GithubHelp home page GithubHelp logo

advanced-git-challenge-2's Introduction

Advanced-Git-Challenge-2

Part 2 Amending Complete the following steps:

[x] Create a new repo or use an existing one [x] Create a new file db.secret with a secret message [x] “Accidentally” commit your secret [x] Take a screenshot of git log -p [x] Fix your mistake: Add db.secret into your .gitignore, remove the secret file from the index (see hint below) and git commit --amend (if you want you can add --no-edit to skip the editor window for the commit message) [x] Take another screenshot of git log -p and post both screenshots to slack

[x] Hint: To remove something only from the index use git rm --cached db.secret this leaves the file in your folder.

Cherry Picking + Amending

[x] Add two more commits to your repo, so you have at least 3 commits Your goal is to change the message of the commit that is 3 steps back (while leaving the two children alone)

Steps: write down the hash of the two latest commits somewhere: git log --oneline (In the following we will refer to them as A, B, C where C is the most recent, they will appear as C B A ) git reset --hard git commit --amend git cherry-pick

advanced-git-challenge-2's People

Contributors

richardkruemmel avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.