summaryrefslogtreecommitdiff
path: root/lib/git/objects
Commit message (Collapse)AuthorAgeFilesLines
...
* | Stream_data streams data to a given output stream most efficiently with a ↵Sebastian Thiel2009-10-221-0/+12
| | | | | | | | | | | | | | | | | | | | | | low memory footprint. Still, the git-cat-file command keeps all data in an interal buffer instead of streaming it directly. This is a git design issue though, and will be hard to address without some proper git-hacking. Conflicts: lib/git/cmd.py
* | added Object.data_stream property allowing to stream object data ↵Sebastian Thiel2009-10-222-0/+30
|/ | | | directly.Considering the implementation of the git commnd which temporarily keeps it in a cache, it doesnt make a huge diffence as the data is kept in memory while streaming. Only good thing is that it is in a different process so python will never see it if done properly
* Implemneted IterableLists for refs, commits and remote objects including ↵Sebastian Thiel2009-10-191-0/+1
| | | | simple tests
* commit.count: is an instance method nowSebastian Thiel2009-10-191-10/+3
| | | | | repo: added head , tag and iter_trees methods for completeness changes: headlines now sorted chronologically
* Improved tagobject message handling by not assuming an empty fourth line anymoreSebastian Thiel2009-10-181-2/+7
|
* resolved cyclic inclusion issue by moving the Diffable interface into the ↵Sebastian Thiel2009-10-183-77/+3
| | | | diff module, which probably is the right thing to do anyway
* implemented diff tests, but will have to move the diff module as it needs to ↵Sebastian Thiel2009-10-181-2/+5
| | | | create objects, whose import would create a dependency cycle
* Removed a few diff-related test cases that fail now as the respective method ↵Sebastian Thiel2009-10-171-0/+1
| | | | is missing - these tests have to be redone in test-diff module accordingly
* added Diffable interface to objects.base, its used by Commit and Tree objects.Sebastian Thiel2009-10-163-56/+74
| | | | Diff class has been prepared to process raw input, but its not yet more than a frame
* Fixed object bug that would cause object ids not to be resolved to sha's as ↵Sebastian Thiel2009-10-161-12/+20
| | | | | | this was assumed - now there is a test for it as well repo: removed diff and commit_diff methods, added 'head' property returning the current head as Reference object
* repo.commit_delta_base: removedSebastian Thiel2009-10-151-75/+78
|
* Object can now create objects of the proper type in case one attempts to ↵Sebastian Thiel2009-10-152-1/+15
| | | | create an object directly - this feature is used in several places now, allowing for additional type-checking
* Added Commit.iter_parents to iterate all parentsSebastian Thiel2009-10-151-10/+32
| | | | | Renamed Commit.commits to iter_commits repo: assured proper use of the terms revision ( rev ) and reference ( ref )
* repo: removed a few methods because of redundancy or because it will be ↵Sebastian Thiel2009-10-151-10/+12
| | | | obsolete once the interface overhaul is finished. This commit is just intermediate
* All times are not stored as time_struct, but as simple int to consume less ↵Sebastian Thiel2009-10-153-28/+34
| | | | | | memory time imports cleaned up and mostly removed as they were not required (anymore)
* tree: now reads tress directly by parsing the binary data, allowing it to ↵Sebastian Thiel2009-10-142-35/+74
| | | | safe possibly hundreds of command calls
* persistent command signature changed to also return the hexsha from a ↵Sebastian Thiel2009-10-141-2/+2
| | | | possible input ref - the objects pointed to by refs are now baked on demand - perhaps it should change to always be re-retrieved using a property as it is relatively fast - this way refs can always be cached
* test_blob: removed many redundant tests that would fail now as the mock ↵Sebastian Thiel2009-10-143-8/+17
| | | | | | cannot handle the complexity of the command backend All objects but Tree now use the persistent command to read their object information - Trees get binary data and would need their own pretty-printing or they need to parse the data themselves which is my favorite
* test: Added time-consuming test which could also be a benchmark in fact - ↵Sebastian Thiel2009-10-144-5/+5
| | | | | | | currently it cause hundreds of command invocations which is slow Fixed issue with trees not properly initialized with their default mode _set_cache_: some objects checked whether the attribute was within their __slots__ although it should have been accessed through its class
* cmd: added option to return the process directly, allowing to read the ↵Sebastian Thiel2009-10-141-6/+8
| | | | | | | output directly from the output stream commit: now reads commit information directly from the output stream of the process by implementing its iterator method repo: removed log method as it was redundant ( equal to the commits method )
* added Iterable interface to Ref typeSebastian Thiel2009-10-131-1/+1
|
* renamed find_all to list_all, changed commit to use iterable interface in ↵Sebastian Thiel2009-10-131-32/+39
| | | | preparation for command changes
* unified name of utils module, recently it was named util and utils in ↵Sebastian Thiel2009-10-132-1/+1
| | | | different packages
* tree: renamed content_from_string to _from_string to make it private. ↵Sebastian Thiel2009-10-131-2/+2
| | | | Removed tests that were testing that method
* tree: now behaves like a list with string indexing functionality - using a ↵Sebastian Thiel2009-10-121-34/+136
| | | | | | dict as cache is a problem as the tree is ordered, added blobs, trees and traverse method repo: remove blob function as blobs are created directly or iterated - primitve types should not clutter the repo interface
* IndexObjects are now checking their slots to raise a proper error message in ↵Sebastian Thiel2009-10-121-1/+8
| | | | case someone tries to access an unset path or mode - this information cannot be retrieved afterwards as IndexObject information is kept in the object that pointed at them. To find this information, one would have to search all objects which is not feasible
* refs now take repo as first argument and derive from LazyMixin to allow them ↵Sebastian Thiel2009-10-122-25/+2
| | | | | | to dynamically retrieve their objects Improved way commits are returned by refs as they now use the path to be sure they always point to the ref even if it changes - previously it would use the sha intead so it would not update after being cached on the ref object
* renamed from_string and list_from_string to _from_string and ↵Sebastian Thiel2009-10-122-8/+8
| | | | _list_from_string to indicate their new status as private method, adjusted all callers respectively
* Reorganized package structure and cleaned up importsSebastian Thiel2009-10-127-0/+702