swcarpentry / DEPRECATED-bc

DEPRECATED: This repository is now frozen - please see individual lesson repositories.
Other
299 stars 383 forks source link

novice: git status --ignored #788

Closed jroth-nber closed 9 years ago

jroth-nber commented 9 years ago

http://www.software-carpentry.org/v5/novice/git/01-backup.html

says

$ git status --ignored

should give results like the following:

# On branch master
# Ignored files:
#  (use "git add -f <file>..." to include in what will be committed)
#
#        a.dat
#        b.dat
#        c.dat
#        results/    

nothing to commit, working directory clean    

However, I am seeing something different:

jroth%> git status --ignored
error: unknown option `ignored'
usage: git status [options] [--] <filepattern>...    

    -v, --verbose         be verbose
    -s, --short           show status concisely
    --porcelain           show porcelain output format
    -z, --null            terminate entries with NUL
    -u, --untracked-files[=<mode>]
                          show untracked files, optional modes: all, normal, no. (Default: all)

Thanks

chendaniely commented 9 years ago

@jroth-nber I updated your message so the output is rendered properly.

FYI: multi-line code blocks are denoted by pre-pending the line with 4 spaces in github markdown

jiffyclub commented 9 years ago

Looks like you're probably using an older Git. The --ignored option was added in Git 1.7.6.3 in 2011. Try updating Git.

jroth-nber commented 9 years ago

Yes, it is an older Git.

Thanks,

Jean