<commit_before># -*- coding: utf-8 -*-
from __future__ import absolute_import, division, print_function, unicode_literals

import lib.git, lib.args, lib.json, lib.time

def commit ( message, duration, authors = None ) :

	authors = lib.args.listify( authors )

	with lib.json.proxy( "contributions.json", mode = "w", default = [] ) as contribs :

		contribs.append( {

			"authors" : authors,
			"message" : message,
			"duration" : duration,
			"timestamp" : lib.time.nanoseconds()

		} )

	lib.git.add( "contributions.json" )
	lib.git.commit( "-m", message )
<commit_msg>convert timestamp to string in contrib<commit_after># -*- coding: utf-8 -*-
from __future__ import absolute_import, division, print_function, unicode_literals

import lib.git, lib.args, lib.json, lib.time

def commit ( message, duration, authors = None ) :

	authors = lib.args.listify( authors )

	with lib.json.proxy( "contributions.json", mode = "w", default = [] ) as contribs :

		contribs.append( {

			"authors" : authors,
			"message" : message,
			"duration" : duration,
			"timestamp" : str( lib.time.nanoseconds() )

		} )

	lib.git.add( "contributions.json" )
	lib.git.commit( "-m", message )

{'fraction_non_alphanumeric': 0.15110356536502548, 'fraction_numerical': 0.001697792869269949, 'mean_word_length': 3.792682926829268, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1963321', 'n_tokens_mistral': 432, 'n_tokens_neox': 384, 'n_words': 98}