在开发人员之间快速共享临时片段
我正在寻找一种在开发人员之间共享代码片段的快速方法。 Visual Studio 允许您使用文件共享作为代码片段的存储库,但 VS Snippet 管理器似乎更适合您想要保留的“永久”代码片段。我只是在寻找一种好方法将代码块发送给其他开发人员查看或复制到他们的代码中。
即时通讯工具往往有字符限制,并且不能很好地保留格式。我可以使用诸如 Pastebin 之类的东西,但我真的不想因为保密原因而将此代码暴露给其他人(无论这些代码片段可能敏感或不敏感,仍然必须维护 NDA)。我知道,Pastebin 有一个私人模式,但对我的老板来说它仍然是一个灰色地带。他们会争辩说,您可能会忘记将其标记为私有,然后代码就会公开。
我可以将片段保存到文件中,然后通过 IM 或文件共享发送它们,但这很麻烦。
理想情况下,我正在寻找免费的东西......开源与否并不重要。我正在寻找一种使用起来非常快的东西,每次片段传输都不会有很多麻烦,并且在共享者和共享者之间是私密的。
我正在考虑为 VS 编写这样一个插件,但如果已经有东西了,我宁愿使用它。因此,如果您有任何建议,我很想听听。
编辑:
我很难相信这样的事情不存在。似乎所有片段管理器都是为长期存储和检索而设计的。理想情况下,我想要像 OneNote 的“便笺”这样的东西,它会弹出一个快速窗口,我可以在其中粘贴一些内容,然后将其发送给同事,然后在他们的屏幕上弹出该窗口。没有存储,没有存档,没有击键集成将其粘贴到您的代码中。
I am looking for a quick way to share code snippets between developers. Visual studio allows you to use a file share as a repository for snippets, but the VS Snippet manager seems more oriented towards "permanent" snippets you want to keep around. I'm just looking for a good way to send a block of code to another developer to look at, or copy into their code.
Instant messengers tend to have character limits and don't really retain formatting well. I could use something like pastebin, but I really don't want to expose this code to others potentially for non-disclosure reasons (regardless of how much those snippets may or may not be sensitive, still have to maintain NDA). I know, Pastebin has a private mode, but it would still be a grey area to my bosses. They would argue that you can forget to mark it private and then the code is out there public.
I could save the snippets to a file, and then send them via IM or file share, but that's just a lot of hassle.
Ideally, i'm looking for something free.. open source or not doesn't matter. And i'm looking for something that's very fast to use without a lot of hassle for each snippit transfer, and is privateish between the sharer and sharee.
I was thinking about writing such a plug-in for VS, but if there's already something out there, i'd rather use that. So if you have any suggestions, i'd love to hear them.
EDIT:
I'm having a hard time believing something like this doesn't exist. It seems all the snippit managers are designed for long term storage and retrieval. Ideally, I'd like something like OneNote's "Side Note" that pops up a quick window, i can past something in it, then send it to a co-worker, then have that pop up in their screen. No storage, no archival, no keystroke integration to paste it into your code..
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
共享 Google 文档文档怎么样?
How about a shared Google Docs document?
如果您使用 GIT,您可以轻松地通过电子邮件发送补丁或共享到公共分支。使用 GIT 的众多好处之一:)
If you are using GIT, you can easily email a patch or share to a common branch. One of the many benefits of using GIT :)