Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

release 0.6.3 #519

Merged
merged 29 commits into from
Nov 21, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
5b71157
closes #496
estebanlm Oct 26, 2017
b172337
close #497
estebanlm Oct 27, 2017
8b52d69
The version of Tonel should be fixed, if it is not the pharo bootstra…
tesonep Nov 4, 2017
4e0614e
Merge pull request #500 from tesonep/fixing-version-of-tonel-for-rele…
estebanlm Nov 4, 2017
c1f465e
Merge with 4e0614e9cd1232d1b634e8b2d394f8f78df1af0a
estebanlm Nov 5, 2017
4b2e620
first approach (branch then commit) working.
estebanlm Nov 9, 2017
8b32e04
IceMergeWorkingCopyCommand working.
estebanlm Nov 9, 2017
f7a6652
Merge pull request #506 from pharo-vcs/verify-sync-before-commiting
estebanlm Nov 10, 2017
fc9c3e0
closes #507
estebanlm Nov 10, 2017
7b3c9f8
Move reference commit to head if no other commit between saved packag…
noha Nov 10, 2017
8664112
Merge pull request #509 from noha/dev-0.6
estebanlm Nov 10, 2017
0d76da1
Trying to do more in order to detect the best version. If there are m…
noha Nov 11, 2017
c2e725f
Add packages comments to Iceberg.
jecisc Nov 11, 2017
bce4d93
Merge pull request #512 from jecisc/cf_comment_iceberg_packages
estebanlm Nov 12, 2017
b12ae9b
After we sorted the anchestry we need to take the first element inste…
noha Nov 12, 2017
ff4e177
Merge pull request #514 from noha/dev-0.6
estebanlm Nov 12, 2017
70031e0
trying to get the right commit for versions when executing load/pull …
estebanlm Nov 12, 2017
2f54595
move validatePullRequest to IceRepository.
estebanlm Nov 13, 2017
ab5b968
validate push can be done before actually trying it.
estebanlm Nov 15, 2017
4a72de3
typo
estebanlm Nov 15, 2017
eac70f9
checkout the merged tree (otherwise is not in working copy and it wil…
estebanlm Nov 15, 2017
6524fb6
handling conflicts when merge.
estebanlm Nov 16, 2017
0a13f9f
catching merge abort exception
estebanlm Nov 16, 2017
00d5caa
ensure we handle conflict error when checking out
estebanlm Nov 16, 2017
823d9c5
validating push before pushing and before commit+push actions.
estebanlm Nov 17, 2017
aecad04
add todo
estebanlm Nov 17, 2017
0346f44
remove bad send to #name
estebanlm Nov 17, 2017
816d487
remove TODO.
estebanlm Nov 20, 2017
1c6754c
update to tonel 1.0.4
estebanlm Nov 21, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ baseline
tonel: spec
spec
baseline: 'Tonel'
with: [ spec repository: 'github://pharo-vcs/tonel:v1.0.?' ]
with: [ spec repository: 'github://pharo-vcs/tonel:v1.0.4' ]
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
I store metadata for this package. These meta data are used by other tools such as the SmalllintManifestChecker and the critics Browser
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
meta-data
description ^ 'I contain the libgit binding for the FileTree export format.

Iceberg can manage different export format and FileTree is one of them. It will export with a file per method format. The pro of this format is that it is easy to get a fine grained history. The cons of this format is that it will create a lot of small files. When a project contains a lot of small file it takes much more space on the disk because of the file system''s blocs minimum space. Also it can cause troubles on windows because of the long names of methods. '
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "<historical>",
"super" : "PackageManifest",
"category" : "Iceberg-Libgit-Filetree",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "ManifestIcebergLibgitFiletree",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
meta-data
description ^ 'I contain the libgit binding for the Tonel export format.

Iceberg can manage different export format and Tonel is one of them. It will export with a file per class format. The cons of this format is that it is not easy to get a fine grained history. The pros of this format is that it will create bigger files than FileTree. When a project contains a lot of small file it takes much more space on the disk because of the file system''s blocs minimum space. Tonel also reduce the troubles on windows because of the long files names that can produce FileTree. '
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ addFilesToIndex: aListOfPaths
| index |
index := repo index.
index addAll: aListOfPaths.
index writeToDisk.
]
index writeToDisk ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
private merging
commitRepository: repo mergedIndex: mergedIndex message: aString mine: myCommit theirs: theirCommit
"Commit mergedIndex"
| signature treeId |

signature := repo defaultSignature.
treeId := mergedIndex writeTreeAndReturnOid.
[ repo checkout_treeish: (LGitTree of: repo fromId: treeId) ]
on: LGit_GIT_ECONFLICT
do: [ :e | e resignalAs: IceMergeAborted new ].

(LGitCommitBuilder of: repo)
tree: (LGitTree of: repo fromId: treeId);
message: 'Merge with ' , aString;
parents:{ myCommit. theirCommit };
updateReference: repo head name;
author: signature;
committer: signature;
writeCommit
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
actions
createBranchFrom: aCommitInfo named: branchName
self withRepoDo: [ :repo | | newBranch |
newBranch := repo
createBranch: branchName
targetId: (LGitId fromHexString: aCommitInfo commitId)
force: false.
repo setHead: newBranch ]
Original file line number Diff line number Diff line change
Expand Up @@ -3,44 +3,16 @@ merge: commitId
self withRepoDo: [ :repo |
| myCommit theirCommit mergeBase |
"Decide if we can fast-forward or we must do a real merge"

myCommit := repo head object.
theirCommit := LGitCommit of: repo fromHexString: commitId.
mergeBase := repo mergeBaseBetween: myCommit id and: theirCommit id.

(mergeBase = myCommit id)
mergeBase = myCommit id
ifTrue: [
"No need to merge, just fast-forward current HEAD"
repo checkout_treeish: theirCommit.
repo head resolve setTargetId: theirCommit id.
]
ifFalse: [
| mergedIndex treeId signature |

"Merge both commits"
mergedIndex := myCommit merge: theirCommit.
mergedIndex hasConflicts
ifTrue: [
"Abort merge and signal for manual merge.
Index is not saved and repository will be discarded,
so no further action is needed to abort the merge"
IceMergeAborted signal
]
ifFalse: [
"Commit mergedIndex"
signature := repo defaultSignature.
treeId := mergedIndex writeTreeAndReturnOid.
repo checkout_treeish: (LGitTree of: repo fromId: treeId).

(LGitCommitBuilder of: repo)
tree: (LGitTree of: repo fromId: treeId);
message: 'Merge with ', commitId;
parents: { myCommit. theirCommit };
updateReference: repo head name;
author: signature;
committer: signature;
writeCommit.

]
]
]
self mergeRepositoryFastForward: repo theirs: theirCommit ]
ifFalse: [
self
mergeRepository: repo
id: commitId
mine: myCommit
theirs: theirCommit ] ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
private merging
mergeRepository: repo id: commitId mine: myCommit theirs: theirCommit
| mergedIndex |

mergedIndex := myCommit merge: theirCommit.
mergedIndex hasConflicts
ifTrue: [
"Abort merge and signal for manual merge.
Index is not saved and repository will be discarded,
so no further action is needed to abort the merge"
IceMergeAborted signal ].

"Commit mergedIndex"
self
commitRepository: repo
mergedIndex: mergedIndex
message: commitId
mine: myCommit
theirs: theirCommit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
private merging
mergeRepositoryFastForward: repo theirs: theirCommit
repo checkout_treeish: theirCommit.
repo head resolve setTargetId: theirCommit id
Original file line number Diff line number Diff line change
Expand Up @@ -13,28 +13,5 @@ pullFrom: aRemote
mergeBase := repo mergeBaseBetween: myCommit id and: theirCommit id.

(mergeBase = myCommit id)
ifTrue: [
"No need to merge, just fast-forward current HEAD"
repo checkout_treeish: repo head upstream object.
repo fastForward
]
ifFalse: [
| mergedIndex treeId signature |

"Merge both commits"
mergedIndex := myCommit merge: theirCommit.

"Commit index"
signature := repo defaultSignature.
treeId := mergedIndex writeTreeAndReturnOid.

(LGitCommitBuilder of: repo)
tree: (LGitTree of: repo fromId: treeId);
message: 'Merge with ', repo head upstream name;
parents: { myCommit. theirCommit };
updateReference: repo head name;
author: signature;
committer: signature;
writeCommit.
]
]
ifTrue: [ self pullRepositoryFastForward: repo ]
ifFalse: [ self pullRepository: repo merge: myCommit with: theirCommit ] ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
private pulling
pullRepository: repo merge: myCommit with: theirCommit
| mergedIndex |

"Merge both commits"
mergedIndex := myCommit merge: theirCommit.
mergedIndex hasConflicts
ifTrue: [ IceMergeAborted signal ].

"Commit index"
self
commitRepository: repo
mergedIndex: mergedIndex
message: repo head upstream name
mine: myCommit
theirs: theirCommit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
private pulling
pullRepositoryFastForward: repo
repo checkout_treeish: repo head upstream object.
repo fastForward
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,19 @@ pushTo: aRemote
reference := repo head.
remoteBranchName := reference name. "TODO: https://github.com/npasserini/iceberg/issues/90"

gitRemote
[ gitRemote
pushWithRefSpec: (LGitRefSpec new
source: reference name;
destination: remoteBranchName;
yourself)
pushOptions: (LGitPushOptions defaults
callbacks: (LGitRemoteCallbacks withProvider: IceCredentialsProvider default);
yourself).
yourself) ]
on: LGit_GIT_ENONFASTFORWARD do: [ :e |
e resignalAs: (IceRemoteDesynchronized new
remote: aRemote;
yourself)].

"Since the push created the branch in the remote, we can now add an upstream to this branch."
reference upstream ifNil: [
reference setUpstream: aRemote remoteName, '/', reference basename ] ]
reference setUpstream: aRemote remoteName, '/', reference basename ] ]
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
I store metadata for this package. These meta data are used by other tools such as the SmalllintManifestChecker and the critics Browser
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
meta-data
description ^ 'I contains the core of the libgit binding of Iceberg.

Libgit is a backend of Iceberg using the LibGit2 (https://libgit2.github.com/) to manage git communication. This package contains to code common to all export format. '
11 changes: 11 additions & 0 deletions Iceberg-Libgit.package/ManifestIcebergLibgit.class/properties.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "<historical>",
"super" : "PackageManifest",
"category" : "Iceberg-Libgit",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "ManifestIcebergLibgit",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
private
splitRootAndSubdirectoryFromLocation
| root subDir |
(self location beginsWith: (self class type, '://'))

(self location beginsWith: (self class type, '://'))
ifFalse: [ self error: 'Invalid URL (It should be ', self class type, '://...)' ].
root := (self location allButFirst: self class type size + 3) asFileReference.
subDir := #().
[ root isNil or: [ self isGitRoot: root ] ]
whileFalse: [
subDir := subDir copyWithFirst: root basename.
root := root parent ].
whileFalse: [
(root asAbsolute = FileSystem workingDirectory)
ifFalse: [ subDir := subDir copyWithFirst: root basename ].
root := root parent ].
root ifNil: [ self error: 'I can''t find a .git/config file.' ].

^ {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
I store metadata for this package. These meta data are used by other tools such as the SmalllintManifestChecker and the critics Browser
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
meta-data
description ^ 'I contains the code related to the Metacello integration of Iceberg.

Metacello is a Smalltalk''s package manager. It help to creation configurations for project to load them and their dependencies.'
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "<historical>",
"super" : "PackageManifest",
"category" : "Iceberg-Metacello-Integration",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "ManifestIcebergMetacelloIntegration",
"type" : "normal"
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,7 @@ newRequestTo: aString
username: self credentials username
password: self credentials password ] ];
headerAt: 'Accept' put: 'application/vnd.github.v3+json';
url: 'https://api.github.com/', aString;
url: 'https://api.github.com/', (aString first = $/
ifTrue: [ aString allButFirst ]
ifFalse: [ aString ]);
yourself
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
I store metadata for this package. These meta data are used by other tools such as the SmalllintManifestChecker and the critics Browser
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
meta-data
description ^ 'I contains a plugin to ease the integration of Iceberg with GitHub''s services.

It provides, for example, the possibility to manage pull requests. '
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "<historical>",
"super" : "PackageManifest",
"category" : "Iceberg-Plugin-GitHub",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "ManifestIcebergPluginGitHub",
"type" : "normal"
}
6 changes: 3 additions & 3 deletions Iceberg-Plugin-GitHub.package/monticello.meta/categories.st
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
SystemOrganization addCategory: #'Iceberg-Plugin-GitHub'!
SystemOrganization addCategory: 'Iceberg-Plugin-GitHub-Model'!
SystemOrganization addCategory: 'Iceberg-Plugin-GitHub-Utils'!
SystemOrganization addCategory: 'Iceberg-Plugin-GitHub-View'!
SystemOrganization addCategory: #'Iceberg-Plugin-GitHub-Model'!
SystemOrganization addCategory: #'Iceberg-Plugin-GitHub-Utils'!
SystemOrganization addCategory: #'Iceberg-Plugin-GitHub-View'!
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
I store metadata for this package. These meta data are used by other tools such as the SmalllintManifestChecker and the critics Browser
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
meta-data
description ^ 'I contains a plugin manager for Iceberg.

This plugin manager allow to extends Iceberg''s functionnalities with modularity.'
11 changes: 11 additions & 0 deletions Iceberg-Plugin.package/ManifestIcebergPlugin.class/properties.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "<historical>",
"super" : "PackageManifest",
"category" : "Iceberg-Plugin",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "ManifestIcebergPlugin",
"type" : "normal"
}
6 changes: 3 additions & 3 deletions Iceberg-Plugin.package/monticello.meta/categories.st
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
SystemOrganization addCategory: #'Iceberg-Plugin'!
SystemOrganization addCategory: 'Iceberg-Plugin-Base'!
SystemOrganization addCategory: 'Iceberg-Plugin-General'!
SystemOrganization addCategory: 'Iceberg-Plugin-Pharo-FogBugz'!
SystemOrganization addCategory: #'Iceberg-Plugin-Base'!
SystemOrganization addCategory: #'Iceberg-Plugin-General'!
SystemOrganization addCategory: #'Iceberg-Plugin-Pharo-FogBugz'!
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@ basicCommitWithMessage: text ifCancel: cancelBlock
self configGitUsernameAndEmailOnCancel: cancelBlock.
e retry ].
self resetText ]
on: NothingToCommit
do: [ :e | UIManager default inform: 'There is nothing to commit.' ]
on: IceNothingToCommit, IceWorkingCopyDesyncronized
do: [ :e | e acceptError: (IceInteractiveErrorVisitor repository: self repository) ]
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ commitPushing: pushBoolean
UIManager default
informUserDuring: [ :bar |
bar label: ('Commiting changes to {1}' format: { self repository name }).
pushBoolean ifTrue: [
"Validate I can push before I do the commit so I can handle fast-forwards (or merges)"
[ self repository validateCanPush ]
on: IceRemoteDesynchronized
do: [ :e | e acceptError: (IceInteractiveErrorVisitor repository: self repository) ] ].
self basicCommitWithMessage: text ifCancel: [ ^ self ].
pushBoolean ifTrue: [ | remote |
remote := self repository pushRemote.
Expand Down
Loading