From 453110303393f46a046ae13c7c2b260b2ed52705 Mon Sep 17 00:00:00 2001 From: Joshua Peek Date: Fri, 3 Aug 2012 15:25:38 -0500 Subject: [PATCH] Forgot to move hidden samples to the correct dir --- lib/linguist/languages.yml | 11 - lib/linguist/samples.json | 1436 +++++++++-------- lib/linguist/samples.rb | 12 +- samples/INI/{ => filenames}/.gitconfig | 0 samples/Perl/{ => filenames}/ack | 0 samples/Shell/{ => filenames}/.bash_profile | 0 samples/Shell/{ => filenames}/.bashrc | 0 samples/Shell/{ => filenames}/.profile | 0 samples/Shell/{ => filenames}/.zlogin | 0 samples/Shell/{ => filenames}/.zshrc | 0 .../{rbenv-sh-shell => rbenv-sh-shell.sh} | 0 samples/Shell/{rvm => rvm.bash} | 0 samples/VimL/{ => filenames}/.gvimrc | 0 samples/VimL/{ => filenames}/.vimrc | 0 samples/YAML/{ => filenames}/.gemrc | 0 15 files changed, 734 insertions(+), 725 deletions(-) rename samples/INI/{ => filenames}/.gitconfig (100%) rename samples/Perl/{ => filenames}/ack (100%) rename samples/Shell/{ => filenames}/.bash_profile (100%) rename samples/Shell/{ => filenames}/.bashrc (100%) rename samples/Shell/{ => filenames}/.profile (100%) rename samples/Shell/{ => filenames}/.zlogin (100%) rename samples/Shell/{ => filenames}/.zshrc (100%) rename samples/Shell/{rbenv-sh-shell => rbenv-sh-shell.sh} (100%) rename samples/Shell/{rvm => rvm.bash} (100%) rename samples/VimL/{ => filenames}/.gvimrc (100%) rename samples/VimL/{ => filenames}/.vimrc (100%) rename samples/YAML/{ => filenames}/.gemrc (100%) diff --git a/lib/linguist/languages.yml b/lib/linguist/languages.yml index 2a1bdeff..65a39648 100644 --- a/lib/linguist/languages.yml +++ b/lib/linguist/languages.yml @@ -597,8 +597,6 @@ INI: - .prefs - .properties primary_extension: .ini - filenames: - - .gitconfig IRC log: lexer: IRC logs @@ -1116,12 +1114,7 @@ Shell: - zsh primary_extension: .sh filenames: - - .bash_profile - - .bashrc - - .profile - - .zlogin - .zsh - - .zshrc - bashrc - zshrc @@ -1238,8 +1231,6 @@ VimL: extensions: - .vim filenames: - - .gvimrc - - .vimrc - vimrc - gvimrc @@ -1307,8 +1298,6 @@ YAML: extensions: - .yaml - .yml - filenames: - - .gemrc eC: type: programming diff --git a/lib/linguist/samples.json b/lib/linguist/samples.json index 8318b7dc..b8ef5d27 100644 --- a/lib/linguist/samples.json +++ b/lib/linguist/samples.json @@ -190,8 +190,8 @@ ], "Shell": [ ".script!", - ".bash", ".sh", + ".bash", ".zsh" ], "Standard ML": [ @@ -232,12 +232,30 @@ ] }, "filenames": { + "INI": [ + ".gitconfig" + ], + "Perl": [ + "ack" + ], "Ruby": [ "Capfile", "Rakefile" ], "Shell": [ + ".bash_profile", + ".bashrc", + ".profile", + ".zlogin", + ".zshrc", "PKGBUILD" + ], + "VimL": [ + ".gvimrc", + ".vimrc" + ], + "YAML": [ + ".gemrc" ] }, "tokens_total": 331500, @@ -19423,222 +19441,769 @@ ".end": 1 }, "Perl": { - "SHEBANG#!perl": 4, - "#": 249, - "use": 70, - "warnings": 15, - ";": 1152, - "strict": 15, - "our": 34, - "VERSION": 15, - "MAIN": 1, - "{": 1100, - "if": 267, - "(": 895, + "package": 14, "App": 129, "Ack": 134, - "ne": 11, - "main": 3, - ")": 893, - "die": 37, - "}": 1113, - "my": 395, - "env_is_usable": 3, - "for": 76, - "@ARGV": 12, - "last": 15, - "_": 100, - "eq": 31, - "/": 68, - "-": 843, - "th": 1, - "[": 154, - "pt": 1, - "]": 150, - "+": 119, - "t": 18, - "&&": 83, - "_thpppt": 3, - "bar": 3, - "_bar": 3, - "no": 19, - "env": 75, - "defined": 55, - "unshift": 4, - "read_ackrc": 4, - "else": 55, - "@keys": 2, - "grep": 17, - "ACK_/": 1, - "keys": 15, - "%": 78, - "ENV": 36, - "delete": 10, - "@ENV": 1, - "load_colors": 1, - "exists": 18, - "ACK_SWITCHES": 1, - "warn": 22, - "show_help": 3, - "exit": 14, - "sub": 222, - "opt": 291, - "get_command_line_options": 4, - "|": 26, - "flush": 7, - "input_from_pipe": 8, - "qw": 32, - "f": 25, - "g": 7, - "l": 17, - "and": 71, - "show_filename": 35, - "regex": 28, - "build_regex": 3, - "shift": 165, - "nargs": 2, - "s": 34, - "res": 59, - "Resource": 5, + ";": 1152, + "use": 70, + "warnings": 15, + "strict": 15, + "File": 49, + "Next": 26, + "Plugin": 2, "Basic": 10, - "new": 52, - "nmatches": 61, - "count": 23, - "search_and_list": 6, - "search_resource": 3, - "close": 19, - "exit_from_ack": 5, - "file_matching": 2, - "||": 47, - "lines": 15, - "check_regex": 2, - "G": 11, - "what": 14, - "get_starting_points": 4, - "iter": 23, - "get_iterator": 4, - "filetype_setup": 4, - "set_up_pager": 3, - "pager": 19, - "print_files": 4, - "elsif": 10, - "print_files_with_matches": 4, - "print_matches": 4, - "fh": 28, "head1": 31, "NAME": 5, + "-": 843, + "A": 2, + "container": 1, + "for": 76, + "functions": 2, + "the": 124, "ack": 38, - "like": 12, - "text": 6, - "finder": 1, + "program": 6, + "VERSION": 15, + "Version": 1, + "cut": 27, + "our": 34, + "COPYRIGHT": 6, + "BEGIN": 7, + "{": 1100, + "}": 1113, + "fh": 28, + "*STDOUT": 4, + "%": 78, + "types": 26, + "type_wanted": 20, + "mappings": 29, + "ignore_dirs": 12, + "input_from_pipe": 8, + "output_to_pipe": 12, + "dir_sep_chars": 10, + "is_cygwin": 6, + "is_windows": 12, + "Spec": 9, + "(": 895, + ")": 893, + "Glob": 2, + "Getopt": 6, + "Long": 6, + "_MTN": 2, + "blib": 2, + "CVS": 5, + "RCS": 2, + "SCCS": 2, + "_darcs": 2, + "_sgbak": 2, + "_build": 2, + "actionscript": 2, + "[": 154, + "qw": 32, + "as": 33, + "mxml": 2, + "]": 150, + "ada": 4, + "adb": 2, + "ads": 2, + "asm": 4, + "s": 34, + "batch": 2, + "bat": 2, + "cmd": 2, + "binary": 3, + "q": 5, + "Binary": 2, + "files": 41, + "defined": 55, + "by": 9, + "Perl": 6, + "T": 2, + "op": 2, + "default": 16, + "off": 4, + "tt": 4, + "tt2": 2, + "ttml": 2, + "vb": 4, + "bas": 2, + "cls": 2, + "frm": 2, + "ctl": 2, + "resx": 2, + "verilog": 2, + "v": 19, + "vh": 2, + "sv": 2, + "vhdl": 4, + "vhd": 2, + "vim": 4, + "yaml": 4, + "yml": 2, + "xml": 6, + "dtd": 2, + "xsl": 2, + "xslt": 2, + "ent": 2, + "while": 27, + "my": 395, + "type": 65, + "exts": 6, + "each": 12, + "if": 267, + "ref": 33, + "ext": 14, + "@": 38, + "push": 30, + "#": 249, + "_": 100, + "mk": 2, + "mak": 2, + "not": 51, + "t": 18, + "p": 9, + "STDIN": 2, + "O": 4, + "eq": 31, + "/MSWin32/": 2, + "quotemeta": 5, + "catfile": 3, "SYNOPSIS": 5, - "options": 7, + "If": 14, + "you": 33, + "want": 5, + "to": 82, + "know": 4, + "about": 3, + "F": 23, + "": 13, + "see": 4, + "file": 36, + "itself.": 2, + "No": 4, + "user": 4, + "serviceable": 1, + "parts": 1, + "inside.": 1, + "is": 57, + "all": 22, + "that": 27, + "should": 2, + "this.": 1, + "FUNCTIONS": 1, + "head2": 32, + "read_ackrc": 4, + "Reads": 1, + "contents": 2, + "of": 46, + ".ackrc": 1, + "and": 71, + "returns": 4, + "arguments.": 1, + "sub": 222, + "@files": 12, + "ENV": 36, + "ACKRC": 2, + "@dirs": 4, + "HOME": 4, + "USERPROFILE": 2, + "dir": 26, + "grep": 17, + "bsd_glob": 4, + "GLOB_TILDE": 2, + "filename": 68, + "&&": 83, + "e": 19, + "open": 7, + "or": 49, + "die": 37, + "@lines": 21, + "/./": 2, + "/": 68, + "s*#/": 2, + "<$fh>": 4, + "chomp": 3, + "close": 19, + "s/": 22, + "+": 119, + "//": 9, + "return": 156, + "get_command_line_options": 4, + "Gets": 3, + "command": 13, + "line": 16, + "arguments": 2, + "does": 10, + "specific": 1, + "tweaking.": 1, + "opt": 291, + "pager": 19, + "ACK_PAGER_COLOR": 7, + "||": 47, + "ACK_PAGER": 5, + "getopt_specs": 6, + "m": 16, + "after_context": 16, + "before_context": 18, + "shift": 165, + "val": 26, + "break": 14, + "c": 5, + "count": 23, + "color": 38, + "ACK_COLOR_MATCH": 5, + "ACK_COLOR_FILENAME": 5, + "ACK_COLOR_LINENO": 4, + "column": 4, + "f": 25, + "flush": 7, + "follow": 7, + "G": 11, + "heading": 18, + "h": 6, + "H": 6, + "i": 26, + "invert_file_match": 8, + "lines": 15, + "l": 17, + "regex": 28, + "n": 16, + "o": 17, + "output": 28, + "undef": 14, + "passthru": 9, + "print0": 7, + "Q": 7, + "show_types": 4, + "smart_case": 3, + "sort_files": 11, + "u": 10, + "w": 4, + "remove_dir_sep": 7, + "delete": 10, + "print_version_statement": 2, + "exit": 14, + "show_help": 3, + "@_": 41, + "show_help_types": 2, + "require": 10, + "Pod": 4, + "Usage": 4, + "pod2usage": 2, + "verbose": 2, + "exitval": 2, + "dummy": 2, + "wanted": 4, + "no//": 2, + "exists": 18, + "else": 55, + "qq": 16, + "Unknown": 2, + "unshift": 4, + "@ARGV": 12, + "split": 13, + "ACK_OPTIONS": 5, + "def_types_from_ARGV": 5, + "filetypes_supported": 5, + "parser": 12, + "Parser": 4, + "new": 52, + "configure": 4, + "getoptions": 4, + "to_screen": 10, + "defaults": 16, + "eval": 9, + "Win32": 9, + "Console": 2, + "ANSI": 3, + "key": 20, + "value": 12, + "<": 14, + "join": 5, + "map": 10, + "@ret": 10, + "from": 19, + "warn": 22, + "..": 5, + "uniq": 4, + "@uniq": 2, + "sort": 6, + "a": 69, + "<=>": 2, + "b": 6, + "keys": 15, + "Go": 1, + "through": 6, + "look": 2, + "I": 67, + "<--type-set>": 1, + "foo=": 1, + "bar": 3, + "<--type-add>": 1, + "xml=": 1, + ".": 118, + "Remove": 1, + "them": 5, + "add": 8, + "supported": 1, + "filetypes": 8, + "i.e.": 2, + "into": 6, + "etc.": 1, + "@typedef": 8, + "td": 6, + "{-": 6, + "-}": 6, + "set": 11, + "Builtin": 4, + "cannot": 4, + "be": 24, + "changed.": 4, + "ne": 11, + "delete_type": 5, + "Type": 2, + "exist": 4, + "creating": 2, + "with": 25, + "...": 2, + "unless": 34, + "@exts": 8, + ".//": 2, + "Cannot": 4, + "append": 2, + "Removes": 1, + "internal": 1, + "structures": 1, + "containing": 5, + "information": 1, + "type_wanted.": 1, + "Internal": 2, + "error": 4, + "builtin": 2, + "ignoredir_filter": 5, + "Standard": 1, + "filter": 16, + "pass": 1, + "L": 18, + "": 1, + "descend_filter.": 1, + "It": 2, + "true": 3, + "directory": 6, + "any": 3, + "ones": 1, + "we": 5, + "ignore.": 1, + "path": 28, + "This": 24, + "removes": 1, + "trailing": 1, + "separator": 2, + "there": 4, + "one": 9, + "its": 2, + "argument": 1, + "Returns": 10, + "list": 10, + "<$filename>": 1, + "could": 2, + "be.": 1, + "For": 5, + "example": 4, + "": 1, + "The": 20, + "filetype": 1, + "will": 7, + "C": 48, + "": 1, + "can": 24, + "it": 23, + "skipped": 2, + "something": 2, + "avoid": 1, + "searching": 6, + "even": 4, + "under": 4, + "a.": 1, + "constant": 2, + "TEXT": 16, + "basename": 9, + ".*": 2, + "is_searchable": 8, + "lc_basename": 8, + "lc": 5, + "r": 10, + "B": 75, + "header": 17, + "SHEBANG#!#!": 2, + "ruby": 3, + "|": 26, + "lua": 2, + "erl": 2, + "hp": 2, + "ython": 2, + "d": 9, + "d.": 2, + "*": 8, + "b/": 4, + "ba": 2, + "k": 6, + "z": 2, + "sh": 2, + "/i": 2, + "search": 11, + "false": 1, + "regular": 3, + "expression": 9, + "found.": 4, + "www": 2, + "U": 2, + "y": 8, + "tr/": 2, + "x": 7, + "w/": 3, + "nOo_/": 2, + "_thpppt": 3, + "_get_thpppt": 3, + "print": 30, + "_bar": 3, + "<<": 6, + "&": 22, + "*I": 2, + "g": 7, + "#.": 6, + ".#": 4, + "I#": 2, + "#I": 6, + "#7": 4, + "results.": 2, + "on": 22, + "when": 17, + "used": 11, + "interactively": 6, + "no": 19, + "Print": 6, + "between": 3, + "results": 9, + "different": 2, + "files.": 6, + "group": 2, + "Same": 8, + "nogroup": 2, + "noheading": 2, + "nobreak": 2, + "Highlight": 2, + "matching": 15, + "text": 6, + "redirected": 2, + "Windows": 4, + "colour": 2, + "COLOR": 6, + "match": 15, + "lineno": 2, + "Set": 3, + "filenames": 7, + "matches": 7, + "numbers.": 2, + "Flush": 2, + "immediately": 2, + "non": 2, + "goes": 2, + "pipe": 4, + "finding": 2, + "Only": 7, + "found": 9, + "without": 3, + "searching.": 2, "PATTERN": 8, + "must": 3, + "specified.": 4, + "REGEX": 2, + "but": 4, + "only": 9, + "REGEX.": 2, + "Sort": 2, + "lexically.": 3, + "invert": 2, + "Print/search": 2, + "handle": 2, + "do": 11, + "g/": 2, + "G.": 2, + "show": 3, + "Show": 2, + "which": 6, + "has.": 2, + "inclusion/exclusion": 2, + "All": 4, + "searched": 5, + "Ignores": 2, + ".svn": 3, + "other": 5, + "ignored": 6, + "directories": 9, + "unrestricted": 2, + "ignore": 5, + "name": 37, + "Add/Remove": 2, + "dirs": 2, + "R": 2, + "recurse": 2, + "Recurse": 3, + "subdirectories": 2, + "END_OF_HELP": 2, + "once": 2, + "VMS": 2, + "vd": 2, + "Term": 6, + "ANSIColor": 8, + "black": 3, + "on_yellow": 3, + "bold": 5, + "green": 3, + "yellow": 3, + "printing": 2, + "qr/": 13, + "last_output_line": 6, + "any_output": 10, + "keep_context": 8, + "@before": 16, + "before_starts_at_line": 10, + "after": 16, + "res": 59, + "next_text": 8, + "has_lines": 4, + "m/": 4, + "regex/": 9, + "next": 9, + "print_match_or_context": 9, + "elsif": 10, + "last": 15, + "max": 12, + "nmatches": 61, + "show_filename": 35, + "context_overall_output_count": 6, + "print_blank_line": 2, + "is_binary": 4, + "is_match": 7, + "starting_line_no": 1, + "match_start": 5, + "match_end": 3, + "Prints": 4, + "out": 2, + "context": 1, + "around": 1, + "match.": 3, + "line_no": 12, + "show_column": 4, + "display_filename": 8, + "colored": 6, + "print_first_filename": 2, + "sep": 8, + "output_func": 8, + "print_separator": 2, + "print_filename": 2, + "display_line_no": 4, + "print_line_no": 2, + "regex/go": 2, + "regex/Term": 2, + "substr": 2, + "/eg": 2, + "z/": 2, + "K/": 2, + "z//": 2, + "print_column_no": 2, + "TOTAL_COUNT_SCOPE": 2, + "total_count": 8, + "get_total_count": 4, + "reset_total_count": 4, + "search_and_list": 6, + "Optimized": 1, + "version": 2, + "lines.": 3, + "ors": 11, + "show_total": 6, + "print_count": 4, + "print_count0": 2, + "filetypes_supported_set": 9, + "True/False": 1, + "are": 24, + "print_files": 4, + "iter": 23, + "returned": 2, + "iterator": 2, + "<$regex>": 1, + "<$one>": 1, + "stop": 1, + "first.": 1, + "record": 1, + "<$ors>": 1, + "<\"\\n\">": 1, + "defines": 1, + "what": 14, + "filename.": 1, + "print_files_with_matches": 4, + "where": 3, + "was": 2, + "repo": 18, + "Repository": 11, + "next_resource": 6, + "print_matches": 4, + "tarballs_work": 4, + ".tar": 2, + ".gz": 2, + "Tar": 4, + "needs_line_scan": 14, + "reset": 5, + "search_resource": 3, + "filetype_setup": 4, + "Minor": 1, + "housekeeping": 1, + "before": 1, + "go": 1, + "expand_filenames": 5, + "reference": 8, + "expanded": 1, + "globs": 1, + "EXPAND_FILENAMES_SCOPE": 2, + "argv": 12, + "attr": 6, + "foreach": 2, + "pattern": 8, + "@results": 16, + "HIDDEN": 2, + "SYSTEM": 2, + "GetAttributes": 2, + "get_starting_points": 4, + "starting": 2, + "@what": 14, + "reslash": 4, + "start_point": 4, + "_match": 8, + "target": 6, + "invert_flag": 4, + "get_iterator": 4, + "Return": 2, + "starting_point": 10, + "g_regex": 4, + "file_filter": 12, + "g_regex/": 6, + "is_interesting": 4, + "descend_filter": 11, + "error_handler": 5, + "msg": 4, + "follow_symlinks": 6, + "set_up_pager": 3, + "Unable": 2, + "going": 1, + "pipe.": 1, + "exit_from_ack": 5, + "Exit": 1, + "application": 10, + "correct": 1, + "code.": 2, + "otherwise": 2, + "number": 1, + "handed": 1, + "in": 29, + "argument.": 1, + "rc": 11, + "LICENSE": 3, + "Copyright": 2, + "Andy": 2, + "Lester.": 2, + "free": 3, + "software": 3, + "redistribute": 3, + "and/or": 3, + "modify": 3, + "terms": 3, + "Artistic": 2, + "License": 2, + "v2.0.": 2, + "SHEBANG#!#! perl": 4, + "examples/benchmarks/fib.pl": 1, + "Fibonacci": 2, + "Benchmark": 1, + "DESCRIPTION": 4, + "Calculates": 1, + "Number": 1, + "": 1, + "unspecified": 1, + "fib": 4, + "N": 2, + "SEE": 3, + "ALSO": 3, + "": 1, + "SHEBANG#!perl": 4, + "MAIN": 1, + "main": 3, + "env_is_usable": 3, + "th": 1, + "pt": 1, + "env": 75, + "@keys": 2, + "ACK_/": 1, + "@ENV": 1, + "load_colors": 1, + "ACK_SWITCHES": 1, + "build_regex": 3, + "nargs": 2, + "Resource": 5, + "file_matching": 2, + "check_regex": 2, + "like": 12, + "finder": 1, + "options": 7, "FILE...": 1, "DIRECTORY...": 1, - "DESCRIPTION": 4, - "is": 57, "designed": 1, - "as": 33, - "a": 69, "replacement": 1, "searches": 1, - "the": 124, "named": 3, "input": 9, "FILEs": 1, - "or": 49, "standard": 1, - "files": 41, - "are": 24, - "file": 36, - "name": 37, "given": 10, - "containing": 5, - "match": 15, - "to": 82, "PATTERN.": 1, "By": 2, - "default": 16, "prints": 2, - "matching": 15, - "lines.": 3, - "can": 24, "also": 7, - "list": 10, - "that": 27, "would": 3, - "be": 24, - "searched": 5, - "without": 3, "actually": 1, - "searching": 6, - "them": 5, "let": 1, - "you": 33, "take": 5, "advantage": 1, - "of": 46, - "know": 4, ".wango": 1, - "I": 67, - "": 13, "won": 1, "throw": 1, "": 4, "away": 1, "because": 3, - "there": 4, "times": 2, - "follow": 7, "symlinks": 1, - "other": 5, "than": 5, "whatever": 1, - "starting": 2, - "directories": 9, "were": 1, "specified": 3, - "on": 22, - "command": 13, "line.": 4, - "This": 24, - "off": 4, - "by": 9, "default.": 2, "item": 42, - "B": 75, - "<": 14, "": 11, - "Only": 7, "paths": 3, "included": 1, - "in": 29, "search.": 1, - "The": 20, "entire": 2, - "path": 28, - "filename": 68, "matched": 1, "against": 1, - "Perl": 6, - "regular": 3, - "expression": 9, - "not": 51, "shell": 4, "glob.": 1, "<-i>": 5, "<-w>": 2, "<-v>": 3, "<-Q>": 4, - "do": 11, "apply": 2, "this": 12, - ".": 118, - "Print": 6, - "where": 3, "relative": 1, - "matches": 7, "option": 5, "convenience": 1, "shortcut": 1, @@ -19647,25 +20212,17 @@ "<--nogroup>": 2, "groups": 1, "with.": 1, - "when": 17, - "used": 11, "interactively.": 1, - "one": 9, "result": 1, "per": 1, - "line": 16, "grep.": 2, - "output": 28, "redirected.": 1, "<-H>": 1, "<--with-filename>": 1, - "each": 12, - "match.": 3, "<-h>": 1, "<--no-filename>": 1, "Suppress": 1, "prefixing": 1, - "filenames": 7, "multiple": 5, "searched.": 1, "<--help>": 1, @@ -19675,26 +20232,16 @@ "<--ignore-case>": 1, "Ignore": 3, "case": 3, - "search": 11, "strings.": 1, "applies": 3, - "only": 9, "regexes": 3, "<-g>": 5, "<-G>": 3, "options.": 4, - "ignore": 5, - "dir": 26, "": 2, - "directory": 6, - "CVS": 5, - ".svn": 3, "etc": 2, - "ignored": 6, "May": 2, "directories.": 2, - "For": 5, - "example": 4, "mason": 1, "users": 4, "may": 3, @@ -19703,14 +20250,10 @@ "<--ignore-dir=data>": 1, "<--noignore-dir>": 1, "allows": 2, - "which": 6, "normally": 1, "perhaps": 1, "research": 1, - "contents": 2, - "F": 23, "<.svn/props>": 1, - "must": 3, "always": 5, "simple": 2, "name.": 1, @@ -19723,19 +20266,13 @@ "specify": 1, "<--ignore-dir=foo>": 1, "then": 3, - "from": 19, - "any": 3, "foo": 6, "taken": 1, - "into": 6, "account": 1, - "unless": 34, "explicitly": 1, "": 2, - "print": 30, "file.": 2, "Multiple": 1, - "with": 25, "<--line>": 1, "comma": 1, "separated": 2, @@ -19758,44 +20295,34 @@ "explicitly.": 1, "helpful": 2, "don": 2, - "through": 6, "": 1, "via": 1, - "C": 48, "": 4, "": 4, "environment": 2, "variables.": 1, "Using": 3, - "does": 10, "suppress": 3, "grouping": 3, "coloring": 3, "piping": 3, "does.": 2, "<--passthru>": 1, - "Prints": 4, - "all": 22, "whether": 1, "they": 1, "expression.": 1, "Highlighting": 1, - "will": 7, "still": 2, "work": 1, "though": 1, "so": 3, - "it": 23, "highlight": 1, - "while": 27, "seeing": 1, "tail": 1, "/access.log": 1, - "passthru": 9, "<--print0>": 1, "works": 1, "conjunction": 1, - "c": 5, "null": 1, "byte": 1, "usual": 1, @@ -19805,7 +20332,6 @@ "whitespace": 1, "e.g.": 1, "html": 1, - "print0": 7, "xargs": 2, "rm": 1, "<--literal>": 1, @@ -19816,7 +20342,6 @@ "<-r>": 1, "<-R>": 1, "<--recurse>": 1, - "Recurse": 3, "just": 2, "here": 1, "compatibility": 2, @@ -19836,18 +20361,13 @@ "option.": 1, "<--sort-files>": 1, "Sorts": 1, - "found": 9, - "lexically.": 3, "Use": 6, - "want": 5, "your": 13, "listings": 1, "deterministic": 1, - "between": 3, "runs": 1, "<--show-types>": 1, "Outputs": 1, - "filetypes": 8, "associates": 1, "Works": 1, "<--thpppt>": 1, @@ -19861,48 +20381,33 @@ "spelling": 1, "<--thpppppt>": 1, "important.": 1, - "It": 2, - "skipped": 2, "make": 3, - "binary": 3, "perl": 8, - "ruby": 3, "php": 2, "python": 1, - "xml": 6, - "exist": 4, "looks": 1, "location.": 1, - "ACK_OPTIONS": 5, "variable": 1, "specifies": 1, "placed": 1, "front": 1, "explicit": 1, - "ACK_COLOR_FILENAME": 5, "Specifies": 4, - "color": 38, "recognized": 1, "attributes": 2, "clear": 2, - "reset": 5, "dark": 1, - "bold": 5, "underline": 1, "underscore": 2, "blink": 1, "reverse": 1, "concealed": 1, - "black": 3, "red": 1, - "green": 3, - "yellow": 3, "blue": 1, "magenta": 1, "on_black": 1, "on_red": 1, "on_green": 1, - "on_yellow": 3, "on_blue": 1, "on_magenta": 1, "on_cyan": 1, @@ -19917,9 +20422,7 @@ "on_color": 1, "background": 1, "color.": 2, - "set": 11, "<--color-filename>": 1, - "ACK_COLOR_MATCH": 5, "printed": 1, "<--color>": 1, "mode.": 1, @@ -19927,50 +20430,37 @@ "See": 1, "": 1, "specifications.": 1, - "ACK_PAGER": 5, - "program": 6, "such": 5, "": 1, "": 1, "": 1, "send": 1, - "its": 2, "output.": 1, "except": 1, - "Windows": 4, "assume": 1, "support": 2, "both": 1, - "specified.": 4, - "ACK_PAGER_COLOR": 7, "understands": 1, - "ANSI": 3, "sequences.": 1, - "If": 14, "never": 1, "back": 3, "ACK": 2, - "&": 22, "OTHER": 1, "TOOLS": 1, - "head2": 32, "Vim": 3, "integration": 3, "integrates": 1, "easily": 2, "editor.": 1, - "Set": 3, "<.vimrc>": 1, "grepprg": 1, "That": 3, "examples": 1, "uses": 1, "<-a>": 1, - "but": 4, "flags.": 1, "Now": 1, "step": 1, - "results": 9, "Dumper": 1, "perllib": 1, "Emacs": 1, @@ -19981,34 +20471,25 @@ "an": 11, "": 1, "extension": 1, - "L": 18, "": 1, "TextMate": 2, "Pedro": 1, "Melo": 1, - "user": 4, "who": 1, "writes": 1, "Shell": 2, - "Return": 2, "Code": 1, "greater": 1, "normal": 1, - "returns": 4, - "return": 156, "code": 7, - "something": 2, - "found.": 4, "<$?=256>": 1, "": 1, "backticks.": 1, "errors": 1, "used.": 1, - "returned": 2, "at": 3, "least": 1, "returned.": 1, - "cut": 27, "DEBUGGING": 1, "PROBLEMS": 1, "gives": 2, @@ -20017,33 +20498,24 @@ "forgotten": 1, "<--noenv>": 1, "<.ackrc>": 1, - "see": 4, "remember.": 1, "Put": 1, - "type": 65, - "add": 8, "definitions": 1, "it.": 1, "smart": 1, "too.": 1, - "sort": 6, "there.": 1, "working": 1, "big": 1, "codesets": 1, "more": 2, - "files.": 6, "create": 2, "tree": 1, "ideal": 1, "sending": 1, "": 1, - "p": 9, - "i": 26, - "e": 19, "prefer": 1, "doubt": 1, - "about": 3, "day": 1, "find": 1, "trouble": 1, @@ -20059,7 +20531,6 @@ "log": 3, "scanned": 1, "twice.": 1, - "Q": 7, "aa.bb.cc.dd": 1, "/path/to/access.log": 1, "B5": 1, @@ -20111,7 +20582,6 @@ "great": 1, "did": 1, "replace": 2, - "No": 4, "read": 6, "only.": 1, "has": 2, @@ -20137,8 +20607,6 @@ "ack.": 2, "Yes": 1, "know.": 1, - "package": 14, - "out": 2, "nothing": 1, "suggest": 1, "symlink": 1, @@ -20166,66 +20634,28 @@ "Signes": 1, "Pete": 1, "Krawczyk.": 1, - "COPYRIGHT": 6, - "LICENSE": 3, - "Copyright": 2, - "Andy": 2, - "Lester.": 2, - "free": 3, - "software": 3, - "redistribute": 3, - "and/or": 3, - "modify": 3, - "under": 4, - "terms": 3, - "Artistic": 2, - "License": 2, - "v2.0.": 2, - "File": 49, - "Next": 26, - "Spec": 9, "files_defaults": 3, "skip_dirs": 3, - "BEGIN": 7, - "file_filter": 12, - "undef": 14, - "descend_filter": 11, - "error_handler": 5, "CORE": 3, - "@_": 41, - "sort_files": 11, - "follow_symlinks": 6, - "map": 10, "curdir": 1, "updir": 1, "__PACKAGE__": 1, "parms": 15, "@queue": 8, "_setup": 2, - "filter": 16, "fullpath": 12, "splice": 2, "local": 5, - "next": 9, "wantarray": 3, - "d": 9, "_candidate_files": 2, "sort_standard": 2, "cmp": 2, "sort_reverse": 1, - "reslash": 4, "@parts": 3, - "split": 13, - "//": 9, - "catfile": 3, - "defaults": 16, "passed_parms": 6, - "ref": 33, - "key": 20, "badkey": 1, "caller": 2, "start": 6, - "push": 30, "dh": 4, "opendir": 1, "@newfiles": 5, @@ -20234,173 +20664,6 @@ "has_stat": 3, "catdir": 1, "closedir": 1, - "@": 38, - "*STDOUT": 4, - "types": 26, - "type_wanted": 20, - "mappings": 29, - "ignore_dirs": 12, - "output_to_pipe": 12, - "dir_sep_chars": 10, - "is_cygwin": 6, - "is_windows": 12, - "Glob": 2, - "Getopt": 6, - "Long": 6, - "_MTN": 2, - "blib": 2, - "RCS": 2, - "SCCS": 2, - "_darcs": 2, - "_sgbak": 2, - "_build": 2, - "actionscript": 2, - "mxml": 2, - "ada": 4, - "adb": 2, - "ads": 2, - "asm": 4, - "batch": 2, - "bat": 2, - "cmd": 2, - "q": 5, - "Binary": 2, - "T": 2, - "op": 2, - "tt": 4, - "tt2": 2, - "ttml": 2, - "vb": 4, - "bas": 2, - "cls": 2, - "frm": 2, - "ctl": 2, - "resx": 2, - "verilog": 2, - "v": 19, - "vh": 2, - "sv": 2, - "vhdl": 4, - "vhd": 2, - "vim": 4, - "yaml": 4, - "yml": 2, - "dtd": 2, - "xsl": 2, - "xslt": 2, - "ent": 2, - "exts": 6, - "ext": 14, - "mk": 2, - "mak": 2, - "STDIN": 2, - "O": 4, - "/MSWin32/": 2, - "quotemeta": 5, - "@files": 12, - "ACKRC": 2, - "@dirs": 4, - "HOME": 4, - "USERPROFILE": 2, - "bsd_glob": 4, - "GLOB_TILDE": 2, - "open": 7, - "@lines": 21, - "/./": 2, - "s*#/": 2, - "<$fh>": 4, - "chomp": 3, - "s/": 22, - "getopt_specs": 6, - "m": 16, - "after_context": 16, - "before_context": 18, - "val": 26, - "break": 14, - "ACK_COLOR_LINENO": 4, - "column": 4, - "heading": 18, - "h": 6, - "H": 6, - "invert_file_match": 8, - "n": 16, - "o": 17, - "show_types": 4, - "smart_case": 3, - "u": 10, - "w": 4, - "remove_dir_sep": 7, - "print_version_statement": 2, - "show_help_types": 2, - "require": 10, - "Pod": 4, - "Usage": 4, - "pod2usage": 2, - "verbose": 2, - "exitval": 2, - "dummy": 2, - "wanted": 4, - "no//": 2, - "qq": 16, - "Unknown": 2, - "def_types_from_ARGV": 5, - "filetypes_supported": 5, - "parser": 12, - "Parser": 4, - "configure": 4, - "getoptions": 4, - "to_screen": 10, - "eval": 9, - "Win32": 9, - "Console": 2, - "value": 12, - "join": 5, - "@ret": 10, - "..": 5, - "uniq": 4, - "@uniq": 2, - "<=>": 2, - "b": 6, - "@typedef": 8, - "td": 6, - "{-": 6, - "-}": 6, - "Builtin": 4, - "cannot": 4, - "changed.": 4, - "delete_type": 5, - "Type": 2, - "creating": 2, - "...": 2, - "@exts": 8, - ".//": 2, - "Cannot": 4, - "append": 2, - "Internal": 2, - "error": 4, - "builtin": 2, - "ignoredir_filter": 5, - "constant": 2, - "TEXT": 16, - "basename": 9, - ".*": 2, - "is_searchable": 8, - "lc_basename": 8, - "lc": 5, - "r": 10, - "header": 17, - "SHEBANG#!#!": 2, - "lua": 2, - "erl": 2, - "hp": 2, - "ython": 2, - "d.": 2, - "*": 8, - "b/": 4, - "ba": 2, - "k": 6, - "z": 2, - "sh": 2, "": 1, "these": 1, "updated": 1, @@ -20413,156 +20676,14 @@ "js": 1, "1": 1, "str": 12, - "w/": 3, "regex_is_lc": 2, - "qr/": 13, - "regex/": 9, "S": 1, ".*//": 1, "_my_program": 3, "Basename": 2, - "_get_thpppt": 3, - "y": 8, - "www": 2, - "U": 2, - "tr/": 2, - "x": 7, - "nOo_/": 2, - "<<": 6, - "*I": 2, - "#.": 6, - ".#": 4, - "I#": 2, - "#I": 6, - "#7": 4, - "results.": 2, - "interactively": 6, - "different": 2, - "group": 2, - "Same": 8, - "nogroup": 2, - "noheading": 2, - "nobreak": 2, - "Highlight": 2, - "redirected": 2, - "colour": 2, - "COLOR": 6, - "lineno": 2, - "numbers.": 2, - "Flush": 2, - "immediately": 2, - "even": 4, - "non": 2, - "goes": 2, - "pipe": 4, - "finding": 2, - "searching.": 2, - "REGEX": 2, - "REGEX.": 2, - "Sort": 2, - "invert": 2, - "Print/search": 2, - "handle": 2, - "g/": 2, - "G.": 2, - "show": 3, - "Show": 2, - "has.": 2, - "inclusion/exclusion": 2, - "All": 4, - "Ignores": 2, - "unrestricted": 2, - "Add/Remove": 2, - "dirs": 2, - "R": 2, - "recurse": 2, - "subdirectories": 2, - "END_OF_HELP": 2, - "once": 2, - "VMS": 2, - "vd": 2, - "Term": 6, - "ANSIColor": 8, - "printing": 2, - "last_output_line": 6, - "any_output": 10, - "keep_context": 8, - "@before": 16, - "before_starts_at_line": 10, - "after": 16, - "next_text": 8, - "has_lines": 4, - "m/": 4, - "print_match_or_context": 9, - "max": 12, - "context_overall_output_count": 6, - "print_blank_line": 2, - "is_binary": 4, - "is_match": 7, - "line_no": 12, - "match_start": 5, - "match_end": 3, - "show_column": 4, - "display_filename": 8, - "colored": 6, - "print_first_filename": 2, - "sep": 8, - "output_func": 8, - "print_separator": 2, - "print_filename": 2, - "display_line_no": 4, - "print_line_no": 2, - "regex/go": 2, - "regex/Term": 2, - "substr": 2, - "/eg": 2, - "z/": 2, - "K/": 2, - "z//": 2, - "print_column_no": 2, - "TOTAL_COUNT_SCOPE": 2, - "total_count": 8, - "get_total_count": 4, - "reset_total_count": 4, - "ors": 11, - "show_total": 6, - "print_count": 4, - "print_count0": 2, - "filetypes_supported_set": 9, - "repo": 18, - "Repository": 11, - "next_resource": 6, - "tarballs_work": 4, - ".tar": 2, - ".gz": 2, - "Tar": 4, - "needs_line_scan": 14, - "EXPAND_FILENAMES_SCOPE": 2, - "expand_filenames": 5, - "argv": 12, - "attr": 6, - "foreach": 2, - "pattern": 8, - "@results": 16, - "HIDDEN": 2, - "SYSTEM": 2, - "GetAttributes": 2, - "@what": 14, - "start_point": 4, - "_match": 8, - "target": 6, - "invert_flag": 4, - "starting_point": 10, - "g_regex": 4, - "g_regex/": 6, - "is_interesting": 4, - "msg": 4, - "Unable": 2, - "rc": 11, "FAIL": 12, "Carp": 11, "confess": 2, - "Plugin": 2, "@ISA": 2, "class": 8, "self": 141, @@ -20579,109 +20700,6 @@ "seek": 4, "readline": 1, "nexted": 3, - "A": 2, - "container": 1, - "functions": 2, - "Version": 1, - "itself.": 2, - "serviceable": 1, - "parts": 1, - "inside.": 1, - "should": 2, - "this.": 1, - "FUNCTIONS": 1, - "Reads": 1, - ".ackrc": 1, - "arguments.": 1, - "Gets": 3, - "arguments": 2, - "specific": 1, - "tweaking.": 1, - "Go": 1, - "look": 2, - "<--type-set>": 1, - "foo=": 1, - "<--type-add>": 1, - "xml=": 1, - "Remove": 1, - "supported": 1, - "i.e.": 2, - "etc.": 1, - "Removes": 1, - "internal": 1, - "structures": 1, - "information": 1, - "type_wanted.": 1, - "Standard": 1, - "pass": 1, - "": 1, - "descend_filter.": 1, - "true": 3, - "ones": 1, - "we": 5, - "ignore.": 1, - "removes": 1, - "trailing": 1, - "separator": 2, - "argument": 1, - "Returns": 10, - "<$filename>": 1, - "could": 2, - "be.": 1, - "": 1, - "filetype": 1, - "": 1, - "avoid": 1, - "a.": 1, - "/i": 2, - "false": 1, - "starting_line_no": 1, - "context": 1, - "around": 1, - "Optimized": 1, - "version": 2, - "True/False": 1, - "iterator": 2, - "<$regex>": 1, - "<$one>": 1, - "stop": 1, - "first.": 1, - "record": 1, - "<$ors>": 1, - "<\"\\n\">": 1, - "defines": 1, - "filename.": 1, - "was": 2, - "Minor": 1, - "housekeeping": 1, - "before": 1, - "go": 1, - "reference": 8, - "expanded": 1, - "globs": 1, - "going": 1, - "pipe.": 1, - "Exit": 1, - "application": 10, - "correct": 1, - "code.": 2, - "otherwise": 2, - "number": 1, - "handed": 1, - "argument.": 1, - "SHEBANG#!#! perl": 4, - "examples/benchmarks/fib.pl": 1, - "Fibonacci": 2, - "Benchmark": 1, - "Calculates": 1, - "Number": 1, - "": 1, - "unspecified": 1, - "fib": 4, - "N": 2, - "SEE": 3, - "ALSO": 3, - "": 1, "Foo": 11, "Bar": 1, "@array": 1, @@ -24377,10 +24395,10 @@ "/": 2 }, "Shell": { - "export": 6, - "PATH": 5, "SHEBANG#!bash": 4, "echo": 14, + "export": 6, + "PATH": 5, "#": 5, "pkgname": 1, "stud": 4, @@ -26585,5 +26603,5 @@ "XSLT": 1, "YAML": 1 }, - "md5": "c1a765b2d321e1a0fe84a6f1624b6663" + "md5": "a39ed9f3def428ee59ae9d976e19f36e" } \ No newline at end of file diff --git a/lib/linguist/samples.rb b/lib/linguist/samples.rb index 183e1bc6..8e37e8b8 100644 --- a/lib/linguist/samples.rb +++ b/lib/linguist/samples.rb @@ -45,6 +45,10 @@ module Linguist }) end else + if File.extname(filename) == "" + raise "#{File.join(dirname, filename)} is missing an extension, maybe it belongs in filenames/ subdir" + end + yield({ :path => File.join(dirname, filename), :language => category, @@ -68,18 +72,16 @@ module Linguist each do |sample| language_name = sample[:language] - # TODO: For now skip empty extnames - if sample[:extname] && sample[:extname] != "" + if sample[:extname] db['extnames'][language_name] ||= [] if !db['extnames'][language_name].include?(sample[:extname]) db['extnames'][language_name] << sample[:extname] end end - # TODO: For now skip empty extnames - if fn = sample[:filename] + if sample[:filename] db['filenames'][language_name] ||= [] - db['filenames'][language_name] << fn + db['filenames'][language_name] << sample[:filename] end data = File.read(sample[:path]) diff --git a/samples/INI/.gitconfig b/samples/INI/filenames/.gitconfig similarity index 100% rename from samples/INI/.gitconfig rename to samples/INI/filenames/.gitconfig diff --git a/samples/Perl/ack b/samples/Perl/filenames/ack similarity index 100% rename from samples/Perl/ack rename to samples/Perl/filenames/ack diff --git a/samples/Shell/.bash_profile b/samples/Shell/filenames/.bash_profile similarity index 100% rename from samples/Shell/.bash_profile rename to samples/Shell/filenames/.bash_profile diff --git a/samples/Shell/.bashrc b/samples/Shell/filenames/.bashrc similarity index 100% rename from samples/Shell/.bashrc rename to samples/Shell/filenames/.bashrc diff --git a/samples/Shell/.profile b/samples/Shell/filenames/.profile similarity index 100% rename from samples/Shell/.profile rename to samples/Shell/filenames/.profile diff --git a/samples/Shell/.zlogin b/samples/Shell/filenames/.zlogin similarity index 100% rename from samples/Shell/.zlogin rename to samples/Shell/filenames/.zlogin diff --git a/samples/Shell/.zshrc b/samples/Shell/filenames/.zshrc similarity index 100% rename from samples/Shell/.zshrc rename to samples/Shell/filenames/.zshrc diff --git a/samples/Shell/rbenv-sh-shell b/samples/Shell/rbenv-sh-shell.sh similarity index 100% rename from samples/Shell/rbenv-sh-shell rename to samples/Shell/rbenv-sh-shell.sh diff --git a/samples/Shell/rvm b/samples/Shell/rvm.bash similarity index 100% rename from samples/Shell/rvm rename to samples/Shell/rvm.bash diff --git a/samples/VimL/.gvimrc b/samples/VimL/filenames/.gvimrc similarity index 100% rename from samples/VimL/.gvimrc rename to samples/VimL/filenames/.gvimrc diff --git a/samples/VimL/.vimrc b/samples/VimL/filenames/.vimrc similarity index 100% rename from samples/VimL/.vimrc rename to samples/VimL/filenames/.vimrc diff --git a/samples/YAML/.gemrc b/samples/YAML/filenames/.gemrc similarity index 100% rename from samples/YAML/.gemrc rename to samples/YAML/filenames/.gemrc