Verwandle Diff-Snippets in Bilder, die man gerne teilt — ohne deinen Mac zu verlassen.
Diffs are the single best argument for sharing code as an image: the green and red carry the meaning, and both are lost the moment it becomes plain text.
Codeshot erkennt Diff an dem Code, den du einfügst; es gibt also keine Sprachauswahl, die man falsch treffen kann. Hier ist dasselbe Snippet in drei der 30 mitgelieferten Themes, gerendert mit den Stylesheets der App.
@@ -12,7 +12,7 @@ struct Snapshot {
let code: String
var theme: Theme = .xcode
- var scale: Int = 1+ var scale: Int = 2
func export(to path: URL) throws {
Atom One · dunkel
@@ -12,7 +12,7 @@ struct Snapshot {
let code: String
var theme: Theme = .xcode
- var scale: Int = 1+ var scale: Int = 2
func export(to path: URL) throws {
GitHub · dunkel
@@ -12,7 +12,7 @@ struct Snapshot {
let code: String
var theme: Theme = .xcode
- var scale: Int = 1+ var scale: Int = 2
func export(to path: URL) throws {
Solarized · dunkel
Das passende Theme für Diff
Do not trim the hunk header. The line numbers are what tell people where in the file they are looking.
Die richtige Größe
Lass das Bild dem Inhalt folgen oder lege es auf ein Verhältnis fest — 1:1, 4:3, 3:2, 16:9, 9:16, 2:3 oder 3:4 — und exportiere dann mit 1×, 2× oder 3×, damit es auf Retina-Displays scharf bleibt. Kopiere es mit ⌘⇧C direkt in die Zwischenablage oder sichere mit ⌘S.