Skip to main content

git

branch​

Description​

Method that generates random branch name

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.git.branch());
    1. result
    'capacitor-calculate'

commitEntry​

Description​

Method that generate random commit entry like text

Parameters​

NameTypeDescription
options<Object>You can pass parameters as this object properties
options.merge<Boolean>Define whether the merge string is displayed or not

Returns​

  • <String>

Usage​

  1. Without passing parameters

    1. code
    console.log(pure.git.commitEntry());
    1. result
    'commit 38a601280ee427c21ff340ed7ee3f4125b8ca68b\r\n' +
    'Author: Hugo Pieterse <vincent_smit@mail.com>\r\n' +
    'Date: Mon Oct 18 2021 01:57:57 GMT-0300 \r\n' +
    '\r\n' +
    ' generate wireless alarm\r\n'
  2. Describing that i want the merge string to be displayed

    1. code
    console.log(pure.git.commitEntry({ merge: true }));
    1. result
    'commit 51c05bd704f0ec3671c119991201afc8f581d6af\r\n' +
    'Merge: 5c68242 5c68242\r\n' +
    'Author: Audrey Erasmus <harvey.bosch@mail.com>\r\n' +
    'Date: Mon Oct 18 2021 14:34:49 GMT-0300 \r\n' +
    '\r\n' +
    ' input back-end circuit\r\n'

commitMessage​

Description​

Method that generate random commit message

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.git.commitMessage());
    1. result
    'back-up mobile port'

commitSha​

Description​

Method that generate random commit SHA

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.git.commitSha());
    1. result
    'f9d674ba7cdebc1253edad44780468bf168ec7e8'

shortSha​

Description​

Method that generate random short commit SHA

Parameters​

NameTypeDescription
N/AN/AThis method doesn't receive any parameters

Returns​

  • <String>

Usage​

  1. Without passing parameters
    1. code
    console.log(pure.git.shortSha());
    1. result
    '5dee619'