UNPKG

node-git-2-json

Version:

Simple tool to get a JSON from your git log. Inspired by @fabien0102/git2json

40 lines 906 B
export const gitFormatMapping = { refs: '%d', hash: '%H', hashAbbrev: '%h', tree: '%T', treeAbbrev: '%t', parents: '%P', parentsAbbrev: '%p', authorName: '%an', authorEmail: '%ae', authorTimestamp: '%at', committerName: '%cn', committerEmail: '%ce', committerTimestamp: '%ct', subject: '%s', body: '%b', notes: '%N' }; export const lightSanitizeRules = [ ['"', '<q>'], ['\\', '\\\\'] ]; export const heavySanitizeRules = [ // eslint-disable-next-line no-control-regex [/[\x00\x08\x0B\x0C\x0E-\x1F]/g, ''] ]; export const sanitizeKeys = [ 'subject', 'body', 'notes' ]; export let loggingPrefix = ''; export function setLoggingPrefix(value) { loggingPrefix = value; } export let loggingEnabled = true; export function setLoggingEnabled(value) { loggingEnabled = value; } //# sourceMappingURL=constants.js.map