Skip to content
Closed
Changes from 1 commit
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
33787b1
readline: Added failing test for tab completion
mtharrison Aug 29, 2015
eeffc20
readline: fixed issue with tab completion
mtharrison Aug 29, 2015
a493dab
cpplint: make it possible to run outside git repo
bnoordhuis Sep 5, 2015
b3c4cec
build: make .msi install to "nodejs", not "node"
rvagg Sep 5, 2015
cdfa271
doc: update AUTHORS list
rvagg Aug 31, 2015
7ee58be
crypto: replace rwlocks with simple mutexes
bnoordhuis Sep 7, 2015
3bc7e58
child_process: use stdio.fd even if it is 0
evanlucas Sep 7, 2015
278a926
src: s/ia32/x86 for process.release.libUrl for win
rvagg Sep 5, 2015
b8341e8
deps: float node-gyp v3.0.0
rvagg Sep 5, 2015
154d3f5
build: remote commands on staging in single session
rvagg Sep 7, 2015
c7be08c
cluster: allow shared reused dgram sockets
indutny Aug 25, 2015
31450fc
deps: improve ArrayBuffer performance in v8
indutny Sep 8, 2015
22097a2
node-gyp: float 3.0.1, minor fix for download url
rvagg Sep 8, 2015
297b9ae
build: fix v8_enable_handle_zapping override
skomski Sep 7, 2015
8f87169
doc: fix comma splice in Assertion Testing doc
Trott Sep 7, 2015
380a3d8
2015-09-08, Version 4.0.0 (Stable) Release
rvagg Sep 7, 2015
f8152df
test: expect error for test_lookup_ipv6_hint on FreeBSD
Trott Sep 7, 2015
f442904
doc: describe process API for IPC
sam-github Jun 15, 2015
81a0c0b
win,msi: fix documentation shortcut url
mscdex Sep 10, 2015
d2f70fe
doc: use 3rd person singular for consistency
agcolom Sep 9, 2015
a6d674d
bindings: close after reading module struct
indutny Sep 10, 2015
acb6779
deps: cherry-pick 6da51b4 from v8's upstream
indutny Sep 10, 2015
e1fb0e8
doc: use US English for consistency
agcolom Sep 9, 2015
a1949e8
test: remove valid hostname check in test-dns.js
Trott Sep 9, 2015
2aed0aa
readline: Added failing test for tab completion
mtharrison Aug 29, 2015
e9fd78d
readline: fixed issue with tab completion
mtharrison Aug 29, 2015
ac3f7f4
readline: var => const
mtharrison Sep 11, 2015
9831203
Mergefix
mtharrison Sep 11, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
cpplint: make it possible to run outside git repo
cpplint uses the top-level .git directory to determine what the root is
for #include guards.  If it doesn't find a .git directory, it walks up
all the way to the system root and subsequently complains that guards
must be written as HOME_USER_SRC_NODE_SRC_FILENAME_H_.

This commit replaces the .git-based path munging with a fixed root path
relative to the location of the cpplint script, making it possible to
successfully run `make test` from an extracted tarball.

Fixes: #2693
PR-URL: #2710
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
  • Loading branch information
bnoordhuis committed Sep 6, 2015
commit a493dab2e72d19ddd226cd2094463ddb2354af06
35 changes: 4 additions & 31 deletions tools/cpplint.py
Original file line number Diff line number Diff line change
Expand Up @@ -695,37 +695,10 @@ def RepositoryName(self):
locations won't see bogus errors.
"""
fullname = self.FullName()

if os.path.exists(fullname):
project_dir = os.path.dirname(fullname)

if os.path.exists(os.path.join(project_dir, ".svn")):
# If there's a .svn file in the current directory, we recursively look
# up the directory tree for the top of the SVN checkout
root_dir = project_dir
one_up_dir = os.path.dirname(root_dir)
while os.path.exists(os.path.join(one_up_dir, ".svn")):
root_dir = os.path.dirname(root_dir)
one_up_dir = os.path.dirname(one_up_dir)

prefix = os.path.commonprefix([root_dir, project_dir])
return fullname[len(prefix) + 1:]

# Not SVN? Try to find a git or hg top level directory by searching up
# from the current path.
root_dir = os.path.dirname(fullname)
while (root_dir != os.path.dirname(root_dir) and
not os.path.exists(os.path.join(root_dir, ".git")) and
not os.path.exists(os.path.join(root_dir, ".hg"))):
root_dir = os.path.dirname(root_dir)

if (os.path.exists(os.path.join(root_dir, ".git")) or
os.path.exists(os.path.join(root_dir, ".hg"))):
prefix = os.path.commonprefix([root_dir, project_dir])
return fullname[len(prefix) + 1:]

# Don't know what to do; header guard warnings may be wrong...
return fullname
# XXX(bnoordhuis) Expects that cpplint.py lives in the tools/ directory.
toplevel = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
prefix = os.path.commonprefix([fullname, toplevel])
return fullname[len(prefix) + 1:]

def Split(self):
"""Splits the file into the directory, basename, and extension.
Expand Down