Comments (11)
@rubengmurray @assafmo That problem should be fixed in v2.1.1 which is now on the marketplace.
There was different behavior in Node.js between Windows and Linux that meant this bug slipped through. 😳
from gitweblinks.
Yeah it did used to work, but I can't say that I was using the extension with VS Code for too long with it working, it was probably only a month maximum.
That would be great if you could find a way to at least get it working from the command palette, I really miss it now it's not available.
As a real world example I have 72 repositories inside my work
folder, and I may be in work/microservice/src/dir/file.ts
& want to link to something in there.
Thanks for the suggestion of multi-root workspaces - I'll have a read. I'm always a bit reticent to make changes to things like that when it adjusts a nice familiar (and easy!) pattern locally. I guess I should read about workspaces more generally to find out if I'm missing out on any other benefits from using VS Code in the way I do.
Nice one for the quick response and thanks for maintaining this extension.
from gitweblinks.
I've just published v2.1.0 to the marketplace which should fix this problem. 🎉
The commands should now work from the command palette and the context menu item should be visible if there's a repository within the workspace.
from gitweblinks.
Hi @reduckted,
I just updated to 2.1 and I do see the option appearing in the menu now, but I am receiving this error:
The file 'file:///Users/user/dev/dir/project/src/file.ts' is not tracked by Git.
&
Unable to find the repository for the workspace.
Two separate popups....
The file is definitely tracked by git. I've tested out a couple of project directories in different workspaces.
Same with attempting from the command palette
from gitweblinks.
It looks like there were a bunch of changes around Workspace / Repository management in this diff.
from gitweblinks.
OK very strange. I've tried installing 1.9.0
& 1.8.1
to see if the link re-appears and it doesn't. Same errors occur. Could be a conflict with another extension maybe?
FYI, I'm using Git Blame
, which seems to be working absolutely fine.
from gitweblinks.
Thanks for the bug report!
I might use workspaces in a different way to others, but I usually have a big folder open as the root of the workspace (e.g.
work
) which contains a lot of individual repos (e.g.work/user-microservice
,work/some-other-microservice
).
Ah, I hadn't considered using VS Code that way, but I can definitely see why that would be useful.
The error reads as if the extension is no longer looking through the directories to find the .git folder closest to the file I'm trying to create a link for, instead it just looks into the root of the workspace folder and errors. I'm presuming this is the same reason the option has disappeared from the menu.
Yeah, that's right, although previous versions also looked up from the root of the workspace (i.e. the work
folder), so it's odd that it used to work for you. 😕
I can make the commands look up from the file you're creating the link for, which will make the commands work when you run them from the command palette. I'll see if I can work out a performance-friendly way to detect that there's a Git repository somewhere in the workspace as well, so that the menu item can appear in the context menu.
As a workaround for now, you can try using a multi-root workspace where each repository is added as a workspace.
from gitweblinks.
Hi @reduckted,
I just updated to 2.1 and I do see the option appearing in the menu now, but I am receiving this error:
The file 'file:///Users/user/dev/dir/project/src/file.ts' is not tracked by Git.
&
Unable to find the repository for the workspace.
Two separate popups....
The file is definitely tracked by git. I've tested out a couple of project directories in different workspaces.
Same with attempting from the command palette
This happens to me as well!
from gitweblinks.
@reduckted Thank you! Yeah I'm on Linux, I'll check it out and report back.
And also thank you for this awesome extension! ❤️
from gitweblinks.
Fantastic work @reduckted. Works like a charm.
from gitweblinks.
Yup, works for me too!
from gitweblinks.
Related Issues (20)
- New link format: branch name only (no commit) HOT 2
- Quick link opening HOT 2
- Doesn't work with Git worktrees HOT 1
- Incorrect link format for remote URLs containing username HOT 3
- Not tracked files in v2.1.0. HOT 1
- Feature Request: link and selected text to Markdown format HOT 3
- Support for gitea server or custom links? HOT 3
- Links to multi-line selections on GitHub include an extra line HOT 2
- Link to rendered GitHub files should include `?plain=1` HOT 5
- Special characters in file name should be encoded HOT 2
- Fails to copy link from non-root directory HOT 1
- Feature request: Short SHA Links HOT 2
- Change default remote HOT 3
- request supports for workspace settings HOT 2
- [Feature Suggestion] - Keyboard Shortcut for `Copy Link to Selection` HOT 1
- [Tests] lots of tests fail (104) comparing `master` to `main` HOT 1
- Regression: broken "find next" command in MacOS because of keyboard shortcut hijacking (CMD + G) HOT 7
- Server URI is not a valid URI HOT 7
- Built-in WebLink support for VS Code now exists
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gitweblinks.