|
95117d47
|
2021-10-31T09:45:46
|
|
path: separate git-specific path functions from util
Introduce `git_fs_path`, which operates on generic filesystem paths.
`git_path` will be kept for only git-specific path functionality (for
example, checking for `.git` in a path).
|
|
f0e693b1
|
2021-09-07T17:53:49
|
|
str: introduce `git_str` for internal, `git_buf` is external
libgit2 has two distinct requirements that were previously solved by
`git_buf`. We require:
1. A general purpose string class that provides a number of utility APIs
for manipulating data (eg, concatenating, truncating, etc).
2. A structure that we can use to return strings to callers that they
can take ownership of.
By using a single class (`git_buf`) for both of these purposes, we have
confused the API to the point that refactorings are difficult and
reasoning about correctness is also difficult.
Move the utility class `git_buf` to be called `git_str`: this represents
its general purpose, as an internal string buffer class. The name also
is an homage to Junio Hamano ("gitstr").
The public API remains `git_buf`, and has a much smaller footprint. It
is generally only used as an "out" param with strict requirements that
follow the documentation. (Exceptions exist for some legacy APIs to
avoid breaking callers unnecessarily.)
Utility functions exist to convert a user-specified `git_buf` to a
`git_str` so that we can call internal functions, then converting it
back again.
|
|
cad7a1ba
|
2020-06-05T08:42:38
|
|
clar: include the function name
|
|
f673e232
|
2018-12-27T13:47:34
|
|
git_error: use new names in internal APIs and usage
Move to the `git_error` name in the internal API for error-related
functions.
|
|
8b599528
|
2019-01-08T17:26:14
|
|
Fix Linux warnings
This change fixes -Wmaybe-uninitialized and -Wdeprecated-declarations
warnings on Linux builds
|
|
50d4688c
|
2019-01-04T13:41:50
|
|
tests: add missing asserts
CID 1398597, 1398598
|
|
2a9b0102
|
2015-01-23T14:16:34
|
|
Additional core.autocrlf and core.safecrlf tests
This is a cherry-pick of the tests from the following commits:
core.autocrlf=true and core.safecrlf=true did not fail on LF-only file as vanilla git does
Adding a CRLF-file with core.autocrlf=input and core.safecrlf=true does not fail as with vanilla git
Make files with #CR!=#CRLF not fail with core.safecrlf=true
Reported-by: Yue Lin Ho <b8732003@student.nsysu.edu.tw>
Signed-off-by: Sven Strickroth <email@cs-ware.de>
|
|
59b054cb
|
2018-12-03T13:54:32
|
|
index::crlf: better error reporting in core git tests
Don't simply fail when the expected output does not match the data in
the index; instead, provide a detailed output about the system, file,
and settings that caused the failure so that developers can better
isolate the problem(s).
|
|
021a08b0
|
2018-12-01T22:33:16
|
|
index::crlf: simplify test case
|
|
e417fd99
|
2015-07-01T17:00:16
|
|
crlf tests: use known-good data produced by git
Given a variety of combinations of core.autocrlf, core.safecrlf settings
and attributes settings, test that we add files to index the same way
(regarding OIDs and fatal errors) as a known-good test resource created
by git.git.
Signed-off-by: Sven Strickroth <email@cs-ware.de>
|
|
0cee70eb
|
2014-07-01T14:09:01
|
|
Introduce cl_assert_equal_oid
|
|
16798d08
|
2014-05-19T14:57:09
|
|
Make core.safecrlf work on LF-ending platforms
If you enabled core.safecrlf on an LF-ending platform, we would
error even for files with all LFs. We should only be warning on
irreversible mappings, I think.
|
|
9780020b
|
2014-02-09T13:37:39
|
|
Tests for crlf filtering into the repository
|