Skip to content

Instantly share code, notes, and snippets.

@autosquid
Created March 16, 2018 15:47
Show Gist options
  • Save autosquid/f61c141e237612cc84b76b5493e0d20d to your computer and use it in GitHub Desktop.
Save autosquid/f61c141e237612cc84b76b5493e0d20d to your computer and use it in GitHub Desktop.
once yasnippet conforming to google style
#name : #ifndef XXX; #define XXX; #endif
# key: once
# --
#ifndef ${1: `(upcase (subst-char-in-string ?. ?_ (subst-char-in-string ?/ ?_ (file-relative-name buffer-file-name (projectile-project-root)))))`_}
#define $1
$0
#endif // $1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment