Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removing cscope support #50

Open
mmcco opened this issue Dec 29, 2015 · 5 comments
Open

Removing cscope support #50

mmcco opened this issue Dec 29, 2015 · 5 comments

Comments

@mmcco
Copy link
Contributor

mmcco commented Dec 29, 2015

We removed the cscope features downstream in OpenBSD because it was interfering with privilege dropping via pledge(2).

If I understand correctly, this code lets you view connections between vi and cscope instances, and lets you execute cscope commands from vi.

Is there interest in keeping this code? Do people use it? I suspect that it's very rarely used, and its interference with pledging suggests that it uses privileges and system resources otherwise unnecessary in vi. This is a potentially dangerous combination.

Of course, you can still use cscope with vi - you just won't have these extra features. As a daily (practically minute-ly) cscope user, removing this seems like the best option to me.

If people agree, I'm happy to cook up a diff.

@lichray
Copy link
Owner

lichray commented Dec 29, 2015

Just curious, which part is against pledge(2). Does :e ../*.txt can't be used as well?

@mmcco
Copy link
Contributor Author

mmcco commented Dec 29, 2015

Here's our diff.

@mmcco
Copy link
Contributor Author

mmcco commented Dec 29, 2015

There was a second one that just removed some references from the docs.

@lichray
Copy link
Owner

lichray commented Dec 29, 2015

I'm not sure whether there are people who using it (probably no FreeBSD users since I just found a bug...), but the feature is not that useless -- actually, it's as powerful as that in Vim. Take a look at https://github.com/lattera/freebsd/blob/master/contrib/nvi/docs/internals/cscope.NOTES

It's tricky to setup the keybindings though. <tab> needs to be inputted as ^V^I in the config file, and there needs to be a space before the buffer, like find g "t.

@johnsonjh
Copy link
Contributor

johnsonjh commented Oct 27, 2023

@lichray I know this is an ancient thread but, I was disappointed when NeoVim dropped cscope support, and had to adjust accordingly.

I don't use cscope directly usually - my main use of it with Vim was using it to build the database for CCTree (https://github.com/hari-rangarajan/CCTree) use. OpenVi doesn't have cscope either, since OpenBSD is my upstream.

If you are still using cscope, I'd imagine that GNU Global or Universal CTags would work for most Nvi/Nvi2 users, but I'd recommend not getting rid of the feature unless it's actually causing problems or a maintaince burden. There are probably others using it who don't even remember that it's there working for them in the background.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants