question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

.git directory present within module

See original GitHub issue

This is a really minor issue but thought it was worth reporting 😃

Do you want to request a feature or report a bug? Bug

What is the current behavior? There is a .git directory present within the module at the following path: src/runtimes/web/dom/sockjs/.git

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via https://jsfiddle.net or similar.

During our build process we do a git clean -fdx which results in the following error:

fatal: Not a git repository: node_modules/pusher-js/src/runtimes/web/dom/sockjs/../../../../../.git/modules/sockjs-client

What is the expected behavior? No extraneous .git directories

Which versions of Pusher, and which browsers / OS are affected by this issue? Did this work in previous versions of Pusher? If so, which? Unsure when the issue was introduced, but it exists in 4.1.0 and 4.2.2

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:3
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
leesiocommented, Feb 6, 2019

I assume this issue was caused by somebody publishing to npm after initialising the submodule. I’m sorry this happened, but I believe this is resolved now.

leesio pusher-js-install-test(deneb)$ npm install pusher-js
leesio pusher-js-install-test(deneb)$ ls node_modules/pusher-js/src/runtimes/web/dom/
total 88
drwxr-xr-x   9 leesio  staff   288B  6 Feb 11:52 .
drwxr-xr-x  11 leesio  staff   352B  6 Feb 11:52 ..
-rw-r--r--   1 leesio  staff   498B  6 Feb 11:52 dependencies.ts
-rw-r--r--   1 leesio  staff   2.6K  6 Feb 11:52 dependency_loader.ts
-rw-r--r--   1 leesio  staff    17K  6 Feb 11:52 json2.js
-rw-r--r--   1 leesio  staff   1.5K  6 Feb 11:52 jsonp_request.ts
-rw-r--r--   1 leesio  staff   131B  6 Feb 11:52 script_receiver.ts
-rw-r--r--   1 leesio  staff   1.5K  6 Feb 11:52 script_receiver_factory.ts
-rw-r--r--   1 leesio  staff   2.4K  6 Feb 11:52 script_request.ts
1reaction
AlexanderVangelovcommented, Jun 18, 2018

@willedwards the command “git clean -fdx” is used to remove untracked directories (like node_modules/ added to .gitignore). But if an untracked directory is managed by a different git repository - it is honored. Possible to force it with double -f but Jenkins git clean is using single -f by default.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to make an existing directory within a git repository a git ...
Use git submodule absorbgitdirs. This is what the docs state this command does: If a git directory of a submodule is inside the...
Read more >
git-submodule Documentation - Git
If a git directory of a submodule is inside the submodule, move the git directory of the submodule into its superproject's $GIT_DIR/modules path...
Read more >
Git - Submodules - Git SCM
Git addresses this issue using submodules. Submodules allow you to keep a Git repository as a subdirectory of another Git repository. This lets...
Read more >
gitsubmodules Documentation - Git
On the filesystem, a submodule usually (but not always - see FORMS below) consists of (i) a Git directory located under the $GIT_DIR/modules/...
Read more >
gitmodules Documentation - Git
The .gitmodules file, located in the top-level directory of a Git working tree, is a text file with a syntax matching the requirements...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found