<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/keeping-track-of-directories-using-pushd-and-pop-z2mf1r1bn" -->

---
title: Keeping track of directories using pushd and pop | daily.dev
description: Learn how to use pushd and popd commands in the shell to navigate directories across the filesystem easily and save time.
canonical: https://daily.dev/posts/keeping-track-of-directories-using-pushd-and-pop-z2mf1r1bn
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Keeping track of directories using pushd and pop | daily.dev
og:description: Learn how to use pushd and popd commands in the shell to navigate directories across the filesystem easily and save time.
og:url: https://daily.dev/posts/keeping-track-of-directories-using-pushd-and-pop-z2mf1r1bn
og:image: https://api.daily.dev/og/posts/Z2mF1r1BN.png
og:image:alt: Keeping track of directories using pushd and pop
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Keeping track of directories using pushd and pop

**[Lobsters](https://daily.dev/sources/lobsters)** · 2 min read · 3 upvotes · 0 comments

## Summary

Learn how to use pushd and popd commands in the shell to navigate directories across the filesystem easily and save time.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://www.lewis8s.codes/bash/linux/shell/2024/04/19/Keeping-track-of-directories-using-pushd-and-pop>

---

Tags: [#shell](https://daily.dev/tags/shell), [#bash](https://daily.dev/tags/bash)

[View this post on daily.dev](https://daily.dev/posts/keeping-track-of-directories-using-pushd-and-pop-z2mf1r1bn)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Keeping track of directories using pushd and pop","url":"https://daily.dev/posts/keeping-track-of-directories-using-pushd-and-pop-z2mf1r1bn","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/keeping-track-of-directories-using-pushd-and-pop-z2mf1r1bn"},"datePublished":"2024-04-27T22:35:57.918Z","dateModified":"2024-05-09T09:30:38.138Z","description":"Learn how to use pushd and popd commands in the shell to navigate directories across the filesystem easily and save time.","image":"https://media.daily.dev/image/upload/s--OHB84bZF--/f_auto/v1722860399/public/Placeholder%2010","thumbnailUrl":"https://media.daily.dev/image/upload/s--OHB84bZF--/f_auto/v1722860399/public/Placeholder%2010","isAccessibleForFree":true,"articleSection":"Lobsters","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Lobsters","logo":"https://media.daily.dev/image/upload/s--tl8v_Fku--/f_auto,t_logo/v1698841318/logos/lobste.jpg","url":"https://daily.dev/sources/lobsters"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/keeping-track-of-directories-using-pushd-and-pop-z2mf1r1bn","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":3},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"shell,bash","timeRequired":"PT2M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Lobsters","item":"https://daily.dev/sources/lobsters"},{"@type":"ListItem","position":3,"name":"Keeping track of directories using pushd and pop"}]}
```

