Giter Club home page Giter Club logo

Comments (3)

echuber2 avatar echuber2 commented on May 18, 2024

We might be able to do this, but I'm not sure if we should, because it will no doubt upset or confuse some people who've already got a terminal window open to one of the nested directories when they do "git pull". We'll have to tell them to be sure to go to the root first:

cd `git rev-parse --show-toplevel`
git stash
git pull

We would also have to update a lot of the Makefiles to point to the correct relative path of the master makefile.

In the meantime, you can organize the folders for yourself while maintaining your links to the current locations using symlinks. For example, you could create a script make_course_links.sh in the top directory of the examples:

#!/bin/bash

EXAMPLES_TOP_DIR=$(git rev-parse --show-toplevel)
COURSE_1_SUBDIR=courses/cs-fundamentals-1
COURSE_2_SUBDIR=courses/cs-fundamentals-2
COURSE_3_SUBDIR=courses/cs-fundamentals-3

# go to top directory
cd ${EXAMPLES_TOP_DIR}

# make course directories for organization
mkdir -p ${EXAMPLES_TOP_DIR}/${COURSE_1_SUBDIR}
mkdir -p ${EXAMPLES_TOP_DIR}/${COURSE_2_SUBDIR}
mkdir -p ${EXAMPLES_TOP_DIR}/${COURSE_3_SUBDIR}

# make symbolic links to the examples underneath the course directories
ln -s ${EXAMPLES_TOP_DIR}/cpp-ctor ${EXAMPLES_TOP_DIR}/${COURSE_1_SUBDIR}/cpp-ctor
# ...
# ...

(You'd need to finish adding lines at the bottom to make links for all the examples you want.) Please be careful if you do this. Then you'd run the script like:

chmod +x make_course_links.sh
./make_course_links.sh

This has the benefit of leaving the existing directory structure in place for the sake of git updates.

from coursera.

ZijieKu avatar ZijieKu commented on May 18, 2024

Sure. Sounds good. Thanks!

from coursera.

BrianLDev avatar BrianLDev commented on May 18, 2024

I'll second this! Would be great to have the folders organized by section / course

from coursera.

Related Issues (7)

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.