html5怎么共享代码_快速共享代码的前5个地方

html5怎么共享代码

alt

Collaborative development or getting development help from your peers online dictates that you share code with people, but that’s not always possible. If you’re on IRC, pasting giant blocks of code into a public chat channel is annoying for everyone else, and sharing code via instant messenger or email is clumsy, slow, and hard to read (since those tools lack code formatting and line numbering).

协作开发或在线上获得同仁的开发帮助指示您与他人共享代码,但这并不总是可能的。 如果您使用的是IRC,则将巨大的代码块粘贴到公共聊天频道中会让其他人感到烦恼,而通过即时通讯工具或电子邮件共享代码则笨拙,缓慢且难以阅读(因为这些工具缺少代码格式和行号) )。

That’s where pastebins come in. Pastebins allow developers to post code snippets at shareable, throwaway URLs in order to easily swap code back and forth unobtrusively with one another. There are a large number of pastebin sites, and the differences between them are generally minor. However, below is a list of our top five places to easily and quickly share code. Presented in no particular order.

这就是pastebins的用处。Pastebins允许开发人员在可共享的一次性URL上发布代码段,以便轻松地彼此之间来回交换代码。 pastebin站点数量很多,它们之间的差异通常很小。 但是,以下是我们轻松快速共享代码的前五个位置的列表。 按无特定顺序显示。

糊状 (Pastie)

Pastie isn’t the most feature rich pastebin site out there, nor does it support the most languages, but it is one of the most elegant. What Pastie lacks in features, it makes up for in simplicity and beauty. The site offers private pasting and pastes don’t expire. For more feature rich code pasting, check out Paste2, Pastebin.com, Lodge It, Pastebin.ca, and GnoPaste.

Pastie并不是目前功能最丰富的pastebin网站,也不支持大多数语言,但它是最优雅的网站之一。 Pastie所缺乏的功能,是其简单性和美感的补充。 该网站提供私人粘贴,粘贴不会过期。 欲了解更多功能丰富的代码粘贴,检查出Paste2Pastebin.com洛奇它Pastebin.caGnoPaste

要旨 (Gist)

Gist is one of the most robust paste tools on the Internet. What sets it apart from other pastebins? How about versioning, SSL security for private pastes, support for embedding pastes on other sites, and the ability to push and pull pastes using Git. Like parent site GitHub, public pastes on Gist (called, not surprisingly, “gists”) can be forked by other users with the click of a button.

Gist是Internet上最强大的粘贴工具之一。 是什么让它与其他粘贴框区分开? 版本控制,私有粘贴的SSL安全性,对在其他站点上粘贴粘贴的支持以及使用Git推送和拉取粘贴的能力如何? 就像父网站GitHub一样,其他用户只要单击一下按钮,便可以在Gist上公开粘贴(俗称“ gists”)。

GitHub’s active user community has also contributed to Gist by creating a growing ecosystem of extensions, such as auto-posting to Tumblr and Textmate support. You can even serve Greasemonkey scripts from Gist. Very cool.

GitHub的活跃用户社区还通过创建一个不断扩展的扩展生态系统(例如自动发布到TumblrTextmate支持)为Gist做出了贡献。 您甚至可以从Gist 提供Greasemonkey脚本 。 很酷。

小贴 (TinyPaste)

If you crave pasting that is more succinct and to the point, then perhaps TinyPaste is for you. TinyPaste is a barebones pastebin. Just enter your code and go. No futzing with names, descriptions, choosing a language, etc. Unfortunately that also means syntax highlighting is out the window. But if you just want to paste and go, then TinyPaste might be what you’re looking for. The site also has a Firefox plugin that allows you to paste text from any text source (within the browser) and get the paste URL without ever visiting the TinyPaste site, and it has an API.

如果您希望粘贴更简洁明了,那么TinyPaste也许适合您。 TinyPaste是准系统pastebin。 只需输入您的代码即可。 无需混淆名称,描述,选择语言等。不幸的是,这也意味着高亮显示语法。 但是,如果您只是想粘贴并粘贴,那么TinyPaste可能就是您想要的。 该网站还具有Firefox插件,该插件可让您从任何文本源(在浏览器中)粘贴文本并获得粘贴URL,而无需访问TinyPaste网站,并且它具有API

Also see Snipt, which is billed as a pastebin for Twitter. Theoretically, that means it should function much the same way TwitPic does for images — unfortunately, right now it appears to just be a run of the mill paste site with short URLs for pastes. Hopefully they add things like auto-post to Twitter and the ability to target pastes at specific users via @ replies.

另请参阅Snipt ,它被标为Twitter的pastebin。 从理论上讲,这意味着它的功能应与TwitPic处理图像的方式大致相同-不幸的是,现在看来,它似乎只是轧机粘贴站点的一部分,带有用于粘贴的短URL。 希望他们在Twitter上添加自动发布等功能,并能够通过@回复将粘贴目标定位到特定用户。

乙太板 (EtherPad)

EtherPad is not actually a paste site, but if your reason for pasting is because you’re working through a coding problem with a collaborator, then it might be better than any other site on this list. EtherPad lets users collaborate in real time on text documents. Users each join a workspace and can watch each other make changes in real time — if user A types something new, user B sees it appear on his screen in real time.

EtherPad实际上不是粘贴站点,但是如果您粘贴的原因是因为您正在与协作者一起解决编码问题,那么它可能比此列表上的任何其他站点都要好。 EtherPad允许用户在文本文档上进行实时协作。 每个用户都加入一个工作区,并且可以彼此观看实时更改—如果用户A输入新内容,则用户B会看到它实时显示在屏幕上。

Because EtherPad isn’t a real pastebin, it doesn’t support syntax highlighting for many languages, but adding that should be fairly trivial. It does have line numbering, though, so even lacking syntax highlighting, it should be suitable for collaboratively working through a coding issue in ways that a static pastebin couldn’t hope to match.

由于EtherPad不是真正的pastebin,因此它不支持多种语言的语法高亮显示,但是添加它应该是相当琐碎的。 但是,它确实具有行号,因此,即使缺少语法突出显示,它也应该适合于以静态pastebin无法希望匹配的方式协作解决编码问题。

狙击手 (Snipplr)

Like EtherPad, Snipplr also isn’t really a pastebin. Rather, Snipplr is a public code snippet library, and one of the best. If you want to share your code bits with more than just a few people, Snipplr is a great place. It is a very well designed snippet site with over 10,000 snippets. They have a Textmate bundle, a WordPress plugin, Firefox and Safari bookmarklets, and even a plugin for the somewhat more obscure Gnome text editor Gedit.

像EtherPad一样, Snipplr也不是真正的pastebin。 相反,Snipplr是公共代码段库,也是最好的库之一。 如果您想与不止几个人共享您的代码位,Snipplr是个好地方。 这是一个经过精心设计的摘要站点,包含10,000多个摘要。 他们有一个Textmate捆绑包,一个WordPress插件,Firefox和Safari小书签,甚至还有一个稍微模糊的Gnome文本编辑器Gedit的插件。

Also check out DZone Snippets, which is another large public snippet site.

还可以查看DZone代码段 ,这是另一个大型代码段网站。

If you know of any other good sites or methods to share your code, please share them in the comments below. And if you liked this post, be sure to check out 7 Places to Find the Code You Need.

如果您知道共享代码的其他好网站或方法,请在下面的评论中分享。 如果您喜欢这篇文章,请务必查看7个查找所需代码的地方

翻译自: https://www.sitepoint.com/top-5-places-to-share-code-quickly/

html5怎么共享代码

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值