├── .circleci
└── config.yml
├── .gitattributes
├── .gitconfig
├── .github
├── CODEOWNERS
├── ISSUE_TEMPLATE
│ ├── bug_report.md
│ ├── feature_request.md
│ └── help_or_support.md
└── dependabot.yml
├── .gitignore
├── CHANGE-NOTES.md
├── CONTRIBUTING.md
├── DESCRIPTION.html
├── LICENSE
├── README.md
├── _config.yml
├── backend
├── api
│ ├── build.gradle.kts
│ └── src
│ │ └── main
│ │ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── backend
│ │ ├── api
│ │ ├── GitMacheteException.java
│ │ ├── GitMacheteMissingForkPointException.java
│ │ ├── IBranchReference.java
│ │ ├── ICommitOfManagedBranch.java
│ │ ├── IForkPointCommitOfManagedBranch.java
│ │ ├── IGitMacheteRepository.java
│ │ ├── IGitMacheteRepositoryCache.java
│ │ ├── IGitMacheteRepositorySnapshot.java
│ │ ├── IGitRebaseParameters.java
│ │ ├── ILocalBranchReference.java
│ │ ├── IManagedBranchSnapshot.java
│ │ ├── INonRootManagedBranchSnapshot.java
│ │ ├── IRemoteTrackingBranchReference.java
│ │ ├── IRootManagedBranchSnapshot.java
│ │ ├── MacheteFileReaderException.java
│ │ ├── NullGitMacheteRepositorySnapshot.java
│ │ ├── OngoingRepositoryOperationType.java
│ │ ├── RelationToRemote.java
│ │ ├── SyncToParentStatus.java
│ │ └── SyncToRemoteStatus.java
│ │ └── hooks
│ │ ├── BaseHookExecutor.java
│ │ ├── ExecutionResult.java
│ │ └── OnExecutionTimeout.java
└── impl
│ ├── build.gradle.kts
│ └── src
│ ├── main
│ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── backend
│ │ └── impl
│ │ ├── BaseBranchReference.java
│ │ ├── BaseManagedBranchSnapshot.java
│ │ ├── CommitOfManagedBranch.java
│ │ ├── CreatedAndDuplicatedAndSkippedBranches.java
│ │ ├── ForkPointCommitOfManagedBranch.java
│ │ ├── GitMacheteRepository.java
│ │ ├── GitMacheteRepositoryCache.java
│ │ ├── GitMacheteRepositorySnapshot.java
│ │ ├── GitRebaseParameters.java
│ │ ├── LocalBranchReference.java
│ │ ├── NonRootManagedBranchSnapshot.java
│ │ ├── RemoteTrackingBranchReference.java
│ │ ├── RootManagedBranchSnapshot.java
│ │ ├── StatusBranchHookExecutor.java
│ │ └── aux
│ │ ├── Aux.java
│ │ ├── CreateGitMacheteRepositoryAux.java
│ │ └── DiscoverGitMacheteRepositoryAux.java
│ └── test
│ ├── java
│ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── backend
│ │ ├── integration
│ │ ├── BaseIntegrationTestSuite.java
│ │ ├── ParentInferenceIntegrationTestSuite.java
│ │ ├── RegenerateCliOutputs.java
│ │ └── StatusAndDiscoverIntegrationTestSuite.java
│ │ └── unit
│ │ ├── BaseGitMacheteRepositoryUnitTestSuite.java
│ │ ├── GitMacheteRepository_deriveCreatedAndDuplicatedAndSkippedBranchesUnitTestSuite.java
│ │ ├── GitMacheteRepository_deriveParentAwareForkPointUnitTestSuite.java
│ │ ├── GitMacheteRepository_deriveRelationToRemoteUnitTestSuite.java
│ │ ├── GitMacheteRepository_deriveSyncToParentStatusUnitTestSuite.java
│ │ └── UnitTestUtils.java
│ └── resources
│ ├── setup-for-diverged-and-older-than.sh-discover.txt
│ ├── setup-for-diverged-and-older-than.sh-status.txt
│ ├── setup-for-overridden-fork-point.sh-discover.txt
│ ├── setup-for-overridden-fork-point.sh-status.txt
│ ├── setup-for-squash-merge.sh-discover.txt
│ ├── setup-for-squash-merge.sh-status.txt
│ ├── setup-for-yellow-edges.sh-discover.txt
│ ├── setup-for-yellow-edges.sh-status.txt
│ ├── setup-with-multiple-remotes.sh-discover.txt
│ ├── setup-with-multiple-remotes.sh-status.txt
│ ├── setup-with-no-remotes.sh-discover.txt
│ ├── setup-with-no-remotes.sh-status.txt
│ ├── setup-with-single-remote.sh-discover.txt
│ ├── setup-with-single-remote.sh-status.txt
│ └── version.txt
├── branchLayout
├── api
│ ├── build.gradle.kts
│ └── src
│ │ ├── main
│ │ └── java
│ │ │ └── com
│ │ │ └── virtuslab
│ │ │ └── branchlayout
│ │ │ └── api
│ │ │ ├── BranchLayout.java
│ │ │ ├── BranchLayoutEntry.java
│ │ │ ├── BranchLayoutException.java
│ │ │ ├── EntryDoesNotExistException.java
│ │ │ ├── EntryIsDescendantOfException.java
│ │ │ └── readwrite
│ │ │ ├── IBranchLayoutReader.java
│ │ │ ├── IBranchLayoutWriter.java
│ │ │ └── IndentSpec.java
│ │ └── test
│ │ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── branchlayout
│ │ └── api
│ │ └── BranchLayoutTestSuite.java
└── impl
│ ├── build.gradle.kts
│ └── src
│ ├── main
│ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── branchlayout
│ │ └── impl
│ │ └── readwrite
│ │ ├── BranchLayoutFileUtils.java
│ │ ├── BranchLayoutReader.java
│ │ └── BranchLayoutWriter.java
│ └── test
│ └── java
│ └── com
│ └── virtuslab
│ └── branchlayout
│ └── impl
│ └── readwrite
│ └── BranchLayoutFileReaderTestSuite.java
├── build.gradle.kts
├── buildSrc
├── build.gradle.kts
├── gradle
│ └── libs.versions.toml
└── src
│ ├── main
│ └── kotlin
│ │ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── buildsrc
│ │ ├── CheckerFramework.kt
│ │ ├── Checkstyle.kt
│ │ ├── Dependencies.kt
│ │ ├── IntellijVersionHelper.kt
│ │ ├── IntellijVersions.kt
│ │ ├── PropertiesHelper.kt
│ │ ├── Spotless.kt
│ │ ├── UiTests.kt
│ │ ├── UpdateIntellijVersions.kt
│ │ └── VersionFromGit.kt
│ └── test
│ └── kotlin
│ └── com
│ └── virtuslab
│ └── gitmachete
│ └── buildsrc
│ ├── IntellijVersionHelperTest.kt
│ └── IntellijVersionsTest.kt
├── config
├── checker
│ ├── com.intellij.astub
│ ├── git4idea.astub
│ ├── io.vavr.astub
│ ├── java.lang.astub
│ ├── java.util.astub
│ ├── javax.swing.astub
│ ├── org.apache.commons.astub
│ └── org.eclipse.jgit.astub
├── checkstyle
│ └── checkstyle.xml
└── spotless
│ └── formatting-rules.xml
├── docs
├── checkout.gif
├── debug_configuration.png
├── discover.gif
├── fast_forward.gif
├── features.md
├── left_bar_actions
│ ├── discover.png
│ ├── edit.png
│ ├── fastForward.png
│ ├── fetch.png
│ ├── ffmerge.png
│ ├── help.png
│ ├── incomingChangesOn.png
│ ├── macheteLogoIcon.png
│ ├── merge.png
│ ├── overrideForkPoint.png
│ ├── pull.png
│ ├── push.png
│ ├── rebase.png
│ ├── reset.png
│ ├── slideIn.png
│ ├── slideOut.png
│ ├── squash.png
│ ├── toggleListingCommits.png
│ └── traverse.png
├── logo-dark.svg
├── logo.svg
├── machete_file_editor.gif
├── medium-blog-post
│ ├── actions-after_dark.png
│ ├── actions-before_dark.png
│ ├── actions_dark.png
│ ├── blog.md
│ ├── gmt_dark.png
│ ├── logo.svg
│ ├── machete-file_dark.png
│ ├── rebase-gm_dark-4x3.gif
│ └── rebase-idea_dark-4x3.gif
├── merge.gif
├── multi_repo.gif
├── open_git_machete.gif
├── override_forkpoint.gif
├── plugins.jetbrains.com
│ ├── getting_started.html
│ ├── sample_status.png
│ ├── scenario-1-review.gif
│ ├── scenario-2-branch-update.gif
│ ├── scenario-3-stacked-prs.gif
│ └── scenario-4-ff-merge.gif
├── pull.gif
├── push.gif
├── rebase.gif
├── rename.png
├── reset.gif
├── sample_graph.png
├── show_in_git_log.gif
├── slide_in_existing_branch.gif
├── slide_in_new_branch.gif
├── slide_in_reattach_with_children.gif
├── slide_in_reattach_without_children.gif
├── slide_in_use_cases.md
├── slide_out_leaf_node.gif
├── slide_out_non_leaf_node.gif
├── squash.gif
└── toggle_listing_commits.gif
├── frontend
├── actions
│ ├── build.gradle.kts
│ └── src
│ │ └── main
│ │ ├── java
│ │ └── com
│ │ │ └── virtuslab
│ │ │ └── gitmachete
│ │ │ └── frontend
│ │ │ └── actions
│ │ │ ├── backgroundables
│ │ │ ├── BaseSlideInBackgroundable.java
│ │ │ ├── FetchBackgroundable.java
│ │ │ ├── GitCommandUpdatingCurrentBranchBackgroundable.java
│ │ │ ├── MergeCurrentBranchFastForwardOnlyBackgroundable.java
│ │ │ ├── OverrideForkPointBackgroundable.java
│ │ │ ├── RebaseOnParentBackgroundable.java
│ │ │ ├── RenameBackgroundable.java
│ │ │ ├── ResetCurrentToRemoteBackgroundable.java
│ │ │ ├── SideEffectingBackgroundable.java
│ │ │ ├── SlideInNonRootBackgroundable.java
│ │ │ └── SlideInRootBackgroundable.java
│ │ │ ├── base
│ │ │ ├── BaseCheckoutAction.java
│ │ │ ├── BaseCompareWithParentAction.java
│ │ │ ├── BaseFastForwardMergeToParentAction.java
│ │ │ ├── BaseGitMacheteRepositoryReadyAction.java
│ │ │ ├── BaseOverrideForkPointAction.java
│ │ │ ├── BaseProjectDependentAction.java
│ │ │ ├── BasePullAction.java
│ │ │ ├── BasePushAction.java
│ │ │ ├── BaseRenameAction.java
│ │ │ ├── BaseResetToRemoteAction.java
│ │ │ ├── BaseSlideInBelowAction.java
│ │ │ ├── BaseSlideOutAction.java
│ │ │ ├── BaseSquashAction.java
│ │ │ ├── BaseSyncToParentByMergeAction.java
│ │ │ ├── BaseSyncToParentByRebaseAction.java
│ │ │ ├── IBranchNameProvider.java
│ │ │ ├── ISyncToParentStatusDependentAction.java
│ │ │ ├── ISyncToRemoteStatusDependentAction.java
│ │ │ └── IWithLogger.java
│ │ │ ├── common
│ │ │ ├── ActionUtils.java
│ │ │ ├── BranchCreationUtils.java
│ │ │ ├── BranchNamesCompletion.java
│ │ │ ├── FastForwardMerge.java
│ │ │ ├── FetchUpToDateTimeoutStatus.java
│ │ │ ├── MergeProps.java
│ │ │ ├── Pull.java
│ │ │ ├── SideEffectingActionTrackingService.java
│ │ │ ├── SlideInOptions.java
│ │ │ ├── SlideInUnmanagedBelowAction.java
│ │ │ ├── SlideOut.java
│ │ │ ├── UiThreadUnsafeRunnable.java
│ │ │ └── VcsCommitMetadataAdapterForSquash.java
│ │ │ ├── contextmenu
│ │ │ ├── CheckoutSelectedAction.java
│ │ │ ├── CompareSelectedWithParentAction.java
│ │ │ ├── FastForwardMergeSelectedToParentAction.java
│ │ │ ├── OverrideForkPointOfSelectedAction.java
│ │ │ ├── PullSelectedAction.java
│ │ │ ├── PushSelectedAction.java
│ │ │ ├── RenameSelectedAction.java
│ │ │ ├── ResetSelectedToRemoteAction.java
│ │ │ ├── ShowSelectedInGitLogAction.java
│ │ │ ├── SlideInBelowSelectedAction.java
│ │ │ ├── SlideOutSelectedAction.java
│ │ │ ├── SquashSelectedAction.java
│ │ │ ├── SyncSelectedToParentByMergeAction.java
│ │ │ ├── SyncSelectedToParentByRebaseAction.java
│ │ │ └── TraverseFromSelectedAction.java
│ │ │ ├── dialogs
│ │ │ ├── GitPushDialog.java
│ │ │ └── TraverseStepConfirmationDialog.java
│ │ │ ├── expectedkeys
│ │ │ ├── IExpectsKeyGitMacheteRepository.java
│ │ │ ├── IExpectsKeySelectedBranchName.java
│ │ │ └── IExpectsKeyUnmanagedBranchName.java
│ │ │ ├── hooks
│ │ │ ├── BaseGit4IdeaHookExecutor.java
│ │ │ ├── PostSlideOutHookExecutor.java
│ │ │ └── PreRebaseHookExecutor.java
│ │ │ ├── navigation
│ │ │ ├── CheckoutFirstChildAction.java
│ │ │ ├── CheckoutNextAction.java
│ │ │ ├── CheckoutParentAction.java
│ │ │ └── CheckoutPreviousAction.java
│ │ │ ├── toolbar
│ │ │ ├── DiscoverAction.java
│ │ │ ├── FastForwardMergeCurrentToParentAction.java
│ │ │ ├── FetchAllRemotesAction.java
│ │ │ ├── HelpAction.java
│ │ │ ├── OpenMacheteFileAction.java
│ │ │ ├── OverrideForkPointOfCurrentAction.java
│ │ │ ├── PullCurrentAction.java
│ │ │ ├── PushCurrentAction.java
│ │ │ ├── ResetCurrentToRemoteAction.java
│ │ │ ├── SlideInBelowCurrentAction.java
│ │ │ ├── SlideOutCurrentAction.java
│ │ │ ├── SquashCurrentAction.java
│ │ │ ├── SyncCurrentToParentByRebaseAction.java
│ │ │ ├── ToggleListingCommitsAction.java
│ │ │ └── TraverseFromFirstAction.java
│ │ │ ├── traverse
│ │ │ ├── BaseTraverseAction.java
│ │ │ ├── CheckoutAndExecute.java
│ │ │ ├── TraverseSyncToParent.java
│ │ │ └── TraverseSyncToRemote.java
│ │ │ └── vcsmenu
│ │ │ └── OpenMacheteTabAction.java
│ │ └── kotlin
│ │ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── frontend
│ │ └── actions
│ │ └── dialogs
│ │ ├── DeleteBranchOnSlideOutSuggestionDialog.kt
│ │ ├── DoNotAskOption.kt
│ │ ├── GitNewBranchDialogCompat.kt
│ │ ├── GitNewCommitMessageActionDialog.kt
│ │ ├── GraphTableDialog.kt
│ │ ├── MyGitNewBranchDialog.kt
│ │ ├── OverrideForkPointDialog.kt
│ │ ├── SlideInDialog.kt
│ │ └── TraverseInfoComponent.kt
├── base
│ ├── build.gradle.kts
│ └── src
│ │ ├── main
│ │ ├── java
│ │ │ └── com
│ │ │ │ └── virtuslab
│ │ │ │ └── gitmachete
│ │ │ │ └── frontend
│ │ │ │ ├── common
│ │ │ │ └── WriteActionUtils.java
│ │ │ │ ├── datakeys
│ │ │ │ └── DataKeys.java
│ │ │ │ ├── defs
│ │ │ │ ├── ActionGroupIds.java
│ │ │ │ ├── ActionIds.java
│ │ │ │ ├── ActionPlaces.java
│ │ │ │ ├── Colors.java
│ │ │ │ ├── FileTypeIds.java
│ │ │ │ ├── GitConfigKeys.java
│ │ │ │ └── PropertiesComponentKeys.java
│ │ │ │ ├── errorreport
│ │ │ │ ├── GitMacheteErrorReportSubmitter.java
│ │ │ │ └── PlatformInfoProvider.java
│ │ │ │ ├── icons
│ │ │ │ └── MacheteIcons.java
│ │ │ │ └── vfsutils
│ │ │ │ └── GitVfsUtils.java
│ │ └── resources
│ │ │ ├── bug_report.md
│ │ │ └── icons
│ │ │ ├── edit.svg
│ │ │ ├── edit_dark.svg
│ │ │ ├── fastForward.svg
│ │ │ ├── fastForward_dark.svg
│ │ │ ├── fetch.svg
│ │ │ ├── fetch_dark.svg
│ │ │ ├── help.svg
│ │ │ ├── help_dark.svg
│ │ │ ├── incomingChangesOn.svg
│ │ │ ├── incomingChangesOn_dark.svg
│ │ │ ├── macheteLogoIcon.svg
│ │ │ ├── macheteLogoIcon32.svg
│ │ │ ├── macheteLogoIcon32_dark.svg
│ │ │ ├── macheteLogoIcon_dark.svg
│ │ │ ├── merge.svg
│ │ │ ├── merge_dark.svg
│ │ │ ├── overrideForkPoint.svg
│ │ │ ├── overrideForkPoint_dark.svg
│ │ │ ├── pull.svg
│ │ │ ├── pull_dark.svg
│ │ │ ├── push.svg
│ │ │ ├── push_dark.svg
│ │ │ ├── rebase.svg
│ │ │ ├── rebase_dark.svg
│ │ │ ├── rename.svg
│ │ │ ├── rename_dark.svg
│ │ │ ├── reset.svg
│ │ │ ├── reset_dark.svg
│ │ │ ├── slideIn.svg
│ │ │ ├── slideIn_dark.svg
│ │ │ ├── slideOut.svg
│ │ │ ├── slideOut_dark.svg
│ │ │ ├── squash.svg
│ │ │ ├── squash_dark.svg
│ │ │ ├── toggleListingCommits.svg
│ │ │ ├── toggleListingCommits_dark.svg
│ │ │ ├── traverse.svg
│ │ │ └── traverse_dark.svg
│ │ └── test
│ │ ├── java
│ │ └── com
│ │ │ └── virtuslab
│ │ │ └── gitmachete
│ │ │ └── frontend
│ │ │ └── errorreport
│ │ │ ├── DummyPlatformInfoProvider.java
│ │ │ └── GitMacheteErrorReportSubmitterTest.java
│ │ └── resources
│ │ └── expected-error-report-uris
│ │ ├── for_multiple_events.txt
│ │ ├── long_uri.txt
│ │ ├── with_stack_trace.txt
│ │ ├── with_suppressed_exceptions.txt
│ │ ├── with_wrapped_exceptions.txt
│ │ └── without_stack_trace.txt
├── file
│ ├── build.gradle.kts
│ └── src
│ │ └── main
│ │ ├── grammar
│ │ ├── Machete.bnf
│ │ └── Machete.flex
│ │ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── frontend
│ │ └── file
│ │ ├── MacheteCompletionContributor.java
│ │ ├── MacheteFileReader.java
│ │ ├── MacheteFileType.java
│ │ ├── MacheteFileUtils.java
│ │ ├── MacheteFileViewProviderFactory.java
│ │ ├── MacheteFileWriter.java
│ │ ├── ReparseMacheteFileOnGitRepositoryChange.java
│ │ ├── codestyle
│ │ ├── MacheteCodeStyleSettingsProvider.java
│ │ └── MacheteLanguageCodeStyleSettingsProvider.java
│ │ ├── grammar
│ │ ├── MacheteElementType.java
│ │ ├── MacheteFile.java
│ │ ├── MacheteLanguage.java
│ │ ├── MacheteLexerAdapter.java
│ │ ├── MacheteParserDefinition.java
│ │ └── MacheteTokenType.java
│ │ ├── highlighting
│ │ ├── MacheteAnnotator.java
│ │ ├── MacheteColorSettingsPane.java
│ │ ├── MacheteSyntaxHighlighter.java
│ │ └── MacheteSyntaxHighlighterFactory.java
│ │ └── quickfix
│ │ └── CreateBranchQuickFix.java
├── graph
│ ├── api
│ │ ├── build.gradle.kts
│ │ └── src
│ │ │ └── main
│ │ │ └── java
│ │ │ └── com
│ │ │ └── virtuslab
│ │ │ └── gitmachete
│ │ │ └── frontend
│ │ │ └── graph
│ │ │ └── api
│ │ │ ├── elements
│ │ │ ├── GraphEdge.java
│ │ │ ├── GraphNode.java
│ │ │ └── IGraphElement.java
│ │ │ ├── items
│ │ │ ├── GraphItemColor.java
│ │ │ ├── IBranchItem.java
│ │ │ ├── ICommitItem.java
│ │ │ └── IGraphItem.java
│ │ │ ├── paint
│ │ │ ├── IGraphCellPainter.java
│ │ │ ├── IGraphCellPainterFactory.java
│ │ │ └── PaintParameters.java
│ │ │ ├── render
│ │ │ ├── IRenderPartGenerator.java
│ │ │ └── parts
│ │ │ │ ├── IEdgeRenderPart.java
│ │ │ │ ├── INodeRenderPart.java
│ │ │ │ └── IRenderPart.java
│ │ │ └── repository
│ │ │ ├── IBranchGetCommitsStrategy.java
│ │ │ ├── IRepositoryGraph.java
│ │ │ ├── IRepositoryGraphCache.java
│ │ │ └── NullRepositoryGraph.java
│ └── impl
│ │ ├── build.gradle.kts
│ │ └── src
│ │ └── main
│ │ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── frontend
│ │ └── graph
│ │ └── impl
│ │ ├── items
│ │ ├── BaseGraphItem.java
│ │ ├── BranchItem.java
│ │ └── CommitItem.java
│ │ ├── paint
│ │ ├── GraphCellPainter.java
│ │ └── GraphCellPainterFactory.java
│ │ ├── render
│ │ ├── GraphItemColorForGraphElementProvider.java
│ │ ├── RenderPartGenerator.java
│ │ └── parts
│ │ │ ├── BaseRenderPart.java
│ │ │ ├── EdgeRenderPart.java
│ │ │ └── NodeRenderPart.java
│ │ └── repository
│ │ ├── RepositoryGraph.java
│ │ ├── RepositoryGraphBuilder.java
│ │ └── RepositoryGraphCache.java
├── resourcebundles
│ ├── build.gradle.kts
│ └── src
│ │ ├── main
│ │ ├── java
│ │ │ └── com
│ │ │ │ └── virtuslab
│ │ │ │ └── gitmachete
│ │ │ │ └── frontend
│ │ │ │ └── resourcebundles
│ │ │ │ └── GitMacheteBundle.java
│ │ └── resources
│ │ │ └── GitMacheteBundle.properties
│ │ └── test
│ │ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── resourcebundles
│ │ └── junit
│ │ └── GitMacheteBundlePropertiesTestSuite.java
└── ui
│ ├── api
│ ├── build.gradle.kts
│ └── src
│ │ └── main
│ │ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── frontend
│ │ └── ui
│ │ └── api
│ │ ├── gitrepositoryselection
│ │ ├── IGitRepositorySelectionChangeObserver.java
│ │ └── IGitRepositorySelectionProvider.java
│ │ └── table
│ │ ├── BaseEnhancedGraphTable.java
│ │ ├── BaseGraphTable.java
│ │ └── ISimpleGraphTableProvider.java
│ └── impl
│ ├── build.gradle.kts
│ └── src
│ └── main
│ └── java
│ └── com
│ └── virtuslab
│ └── gitmachete
│ └── frontend
│ └── ui
│ └── impl
│ ├── RediscoverSuggester.java
│ ├── backgroundables
│ ├── AutodiscoverBackgroundable.java
│ ├── GitMacheteRepositoryUpdateBackgroundable.java
│ └── InferParentForUnmanagedBranchBackgroundable.java
│ ├── cell
│ ├── BranchOrCommitCell.java
│ ├── BranchOrCommitCellRenderer.java
│ └── BranchOrCommitCellRendererComponent.java
│ ├── gitrepositoryselection
│ └── GitRepositoryComboBox.java
│ ├── root
│ ├── GitMacheteContentProvider.java
│ ├── GitMachetePanel.java
│ └── GitMacheteVisibilityPredicate.java
│ └── table
│ ├── DemoGitMacheteRepositorySnapshot.java
│ ├── EnhancedGraphTable.java
│ ├── EnhancedGraphTableMouseAdapter.java
│ ├── EnhancedGraphTablePopupMenuListener.java
│ ├── GraphTableModel.java
│ ├── SimpleGraphTable.java
│ ├── SimpleGraphTableProvider.java
│ ├── UnmanagedBranchNotification.java
│ └── UnmanagedBranchNotificationFactory.java
├── gitCore
├── api
│ ├── build.gradle.kts
│ └── src
│ │ └── main
│ │ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── gitcore
│ │ └── api
│ │ ├── GitCoreCannotAccessGitDirectoryException.java
│ │ ├── GitCoreException.java
│ │ ├── GitCoreNoSuchRevisionException.java
│ │ ├── GitCoreRelativeCommitCount.java
│ │ ├── GitCoreRepositoryState.java
│ │ ├── IGitCoreBranchSnapshot.java
│ │ ├── IGitCoreCheckoutEntry.java
│ │ ├── IGitCoreCommit.java
│ │ ├── IGitCoreCommitHash.java
│ │ ├── IGitCoreHeadSnapshot.java
│ │ ├── IGitCoreLocalBranchSnapshot.java
│ │ ├── IGitCoreObjectHash.java
│ │ ├── IGitCoreReflogEntry.java
│ │ ├── IGitCoreRemoteBranchSnapshot.java
│ │ ├── IGitCoreRepository.java
│ │ ├── IGitCoreRepositoryFactory.java
│ │ └── IGitCoreTreeHash.java
└── jGit
│ ├── build.gradle.kts
│ └── src
│ ├── main
│ └── java
│ │ └── com
│ │ └── virtuslab
│ │ └── gitcore
│ │ └── impl
│ │ └── jgit
│ │ ├── BaseGitCoreBranchSnapshot.java
│ │ ├── BranchFullNameUtils.java
│ │ ├── GitCoreCheckoutEntry.java
│ │ ├── GitCoreCommit.java
│ │ ├── GitCoreCommitHash.java
│ │ ├── GitCoreHeadSnapshot.java
│ │ ├── GitCoreLocalBranchSnapshot.java
│ │ ├── GitCoreObjectHash.java
│ │ ├── GitCoreReflogEntry.java
│ │ ├── GitCoreRemoteBranchSnapshot.java
│ │ ├── GitCoreRepository.java
│ │ ├── GitCoreRepositoryFactory.java
│ │ └── GitCoreTreeHash.java
│ └── test
│ └── java
│ └── com
│ └── virtuslab
│ └── gitcore
│ └── impl
│ └── jgit
│ ├── GitCoreCommitUnitTest.java
│ └── GitCoreRepositoryIntegrationTest.java
├── gradle.properties
├── gradle
├── libs.versions.toml
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── gradlew
├── intellij-versions.properties
├── lombok.config
├── qual
├── build.gradle.kts
└── src
│ └── main
│ └── java
│ └── com
│ └── virtuslab
│ └── qual
│ ├── async
│ ├── BackgroundableQueuedElsewhere.java
│ ├── ContinuesInBackground.java
│ └── DoesNotContinueInBackground.java
│ ├── guieffect
│ ├── IgnoreUIThreadUnsafeCalls.java
│ └── UIThreadUnsafe.java
│ └── subtyping
│ ├── gitmachete
│ ├── backend
│ │ └── api
│ │ │ ├── ConfirmedLocal.java
│ │ │ ├── ConfirmedNonRoot.java
│ │ │ ├── ConfirmedRemote.java
│ │ │ └── ConfirmedRoot.java
│ └── frontend
│ │ └── graph
│ │ └── api
│ │ ├── elements
│ │ ├── ConfirmedGraphEdge.java
│ │ └── ConfirmedGraphNode.java
│ │ └── items
│ │ ├── ConfirmedBranchItem.java
│ │ └── ConfirmedCommitItem.java
│ ├── internal
│ ├── SubtypingBottom.java
│ ├── SubtypingTop.java
│ └── package-info.java
│ └── package-info.java
├── scalafmt.conf
├── scripts
├── close-github-milestone
├── enforce-astub-explicit-annotation-import
├── enforce-change-notes-updated-on-pr-to-master
├── enforce-indent-two-spaces-outside-java
├── enforce-indent-two-spaces-outside-java.awk
├── enforce-issue-number-for-todos
├── enforce-newline-at-eof
├── enforce-properties-keys-with-valid-class-names
├── enforce-settings-gradle-match-directories
├── enforce-shell-scripts-pass-shellcheck
├── enforce-version-bump
├── git-hooks
│ ├── machete-status-branch
│ └── post-commit
├── prohibit-direct-merges-to-master
├── prohibit-java-class-name-hardcode-in-strings
├── prohibit-java-code-commented-out
├── prohibit-java-lines-split-needlessly
├── prohibit-java-lines-split-needlessly.awk
├── prohibit-java-unused-custom-log
├── prohibit-javascript-unbounded-while-loops
├── prohibit-kotlin-undefined-property-keys
├── prohibit-kotlin-unsafe-cast
├── prohibit-non-ascii-characters
├── prohibit-properties-unused-keys
├── prohibit-tab-character
├── prohibit-trailing-whitespace
├── run-pre-build-checks
├── sandbox-setup-utils.sh
├── setup-multiroot-sandbox
├── utils.sh
├── validate-icons
├── validate-markdown-links
└── validate-markdown-values
├── settings.gradle.kts
├── src
├── main
│ └── resources
│ │ └── META-INF
│ │ ├── plugin.xml
│ │ ├── pluginIcon.svg
│ │ └── pluginIcon_dark.svg
├── test
│ ├── java
│ │ └── com
│ │ │ └── virtuslab
│ │ │ └── archunit
│ │ │ ├── BackgroundTaskEnqueuingTestSuite.java
│ │ │ ├── BaseArchUnitTestSuite.java
│ │ │ ├── ClassStructureTestSuite.java
│ │ │ ├── ForbiddenClassesTestSuite.java
│ │ │ ├── ForbiddenFieldsTestSuite.java
│ │ │ ├── ForbiddenMethodsTestSuite.java
│ │ │ ├── MethodCallsTestSuite.java
│ │ │ ├── NamingTestSuite.java
│ │ │ └── UIThreadUnsafeMethodInvocationsTestSuite.java
│ └── kotlin
│ │ └── KPropertyTestSuite.kt
└── uiTest
│ ├── resources
│ ├── common.rhino.js
│ ├── ide.rhino.js
│ ├── ideprobe-common.conf
│ ├── ideprobe-linux.conf
│ ├── ideprobe-macos.conf
│ └── project.rhino.js
│ └── scala
│ └── com
│ └── virtuslab
│ └── gitmachete
│ └── uitest
│ ├── RunningIntelliJFixtureExtension.scala
│ ├── UIScenarioSuite.scala
│ ├── UISuite.scala
│ └── UITestSuite.scala
├── testCommon
├── build.gradle.kts
└── src
│ └── testFixtures
│ ├── java
│ └── com
│ │ └── virtuslab
│ │ └── gitmachete
│ │ └── testcommon
│ │ ├── SetupScripts.java
│ │ ├── TestFileUtils.java
│ │ ├── TestGitRepository.java
│ │ └── TestProcessUtils.java
│ └── resources
│ ├── common.sh
│ ├── setup-for-diverged-and-older-than.sh
│ ├── setup-for-overridden-fork-point.sh
│ ├── setup-for-squash-merge.sh
│ ├── setup-for-yellow-edges.sh
│ ├── setup-readme-scenarios.sh
│ ├── setup-with-multiple-remotes.sh
│ ├── setup-with-no-remotes.sh
│ └── setup-with-single-remote.sh
└── version.gradle.kts
/.gitattributes:
--------------------------------------------------------------------------------
1 | version.gradle.kts merge=version.gradle.kts
2 |
--------------------------------------------------------------------------------
/.gitconfig:
--------------------------------------------------------------------------------
1 | [core]
2 | autocrlf = input
3 | [diff]
4 | renameLimit = 999
5 | renames = copies
6 | [merge "version.gradle.kts"]
7 | name = version.gradle.kts merge driver
8 | driver = cp %B %A
9 | [status]
10 | relativePaths = false
11 | showUntrackedFiles = all
12 |
--------------------------------------------------------------------------------
/.github/CODEOWNERS:
--------------------------------------------------------------------------------
1 | # Note that the rules in CODEOWNERS are NOT additive -
2 | # for any given file, only the LAST matching rule (and not all matching rules) applies.
3 |
4 | * @PawelLipski
5 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/feature_request.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Feature request
3 | about: Request a new feature to the plugin
4 | title: ''
5 | labels: ["externally requested", "feature"]
6 | assignees: ''
7 |
8 | ---
9 |
10 | ## Feature description
11 |
12 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/help_or_support.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Help/Support
3 | about: Ask a question or request support about the plugin
4 | title: ''
5 | labels: ["externally requested", "question"]
6 | assignees: ''
7 |
8 | ---
9 |
10 | ## Question or problem description
11 |
12 |
13 | ## (optional) Screenshots
14 |
16 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | build/
2 | *.class
3 | *.crt
4 | .DS_Store/
5 | **/.gradle/
6 | /gradlew.bat
7 | /*.hprof
8 | /*.hprof.*/
9 | /.idea/
10 | /.intellijPlatform/
11 | *.log
12 | *.pem
13 | .sdkmanrc
14 |
--------------------------------------------------------------------------------
/DESCRIPTION.html:
--------------------------------------------------------------------------------
1 | Probably the sharpest git repository organizer and rebase/merge workflow automation tool you've ever seen!
2 |
3 | This plugin adds an extra tab in the Git tool window that gives an instant answer to the questions:
4 |
12 | * Typically, it is a smell that indicates that the programmer forgot to actually schedule the task. 13 | * Such cases are detected by ArchUnit test {@code com.virtuslab.archunit.BackgroundTaskEnqueuingTestSuite}. 14 | * Still, in some rare cases it might happen that a method passes the newly-created backgroundable 15 | * to downstream APIs to actually enqueue. 16 | * Such methods must be marked as {@link BackgroundableQueuedElsewhere} for {@code BackgroundTaskEnqueuingTestSuite} to ignore. 17 | *
18 | * This annotation must have runtime retention to be visible to ArchUnit tests. 19 | */ 20 | @Retention(RetentionPolicy.RUNTIME) 21 | @Target({ElementType.METHOD}) 22 | public @interface BackgroundableQueuedElsewhere {} 23 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/async/ContinuesInBackground.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.async; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | /** 9 | * Used to mark methods that schedule a background task. 10 | * It is not enforced during compilation whether the annotation is used correctly. 11 | * Its purpose is to make the programmer aware of the increased risk of race conditions, 12 | * esp. to avoid treating such methods as if they completed in a fully synchronous/blocking manner. 13 | *
14 | * As for now, we use an ArchUnit test {@code com.virtuslab.archunit.BackgroundTaskEnqueuingTestSuite} 15 | * to enforce that: 16 | *
22 | * This annotation must have runtime retention to be visible to ArchUnit tests. 23 | */ 24 | @Retention(RetentionPolicy.RUNTIME) 25 | @Target({ElementType.METHOD}) 26 | public @interface ContinuesInBackground {} 27 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/async/DoesNotContinueInBackground.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.async; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | /** 9 | * Used to mark methods that get a free pass on calling {@link ContinuesInBackground} methods, 10 | * despite not being marked as {@link ContinuesInBackground} themselves. 11 | *
12 | * This is only taken into account by ArchUnit test {@code com.virtuslab.archunit.BackgroundTaskEnqueuingTestSuite} 13 | * that enforces the correct usage of {@link ContinuesInBackground} annotation. 14 | *
15 | * This annotation must have runtime retention to be visible to ArchUnit tests. 16 | */ 17 | @Retention(RetentionPolicy.RUNTIME) 18 | @Target({ElementType.METHOD, ElementType.CONSTRUCTOR}) 19 | public @interface DoesNotContinueInBackground { 20 | String reason(); 21 | } 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/guieffect/IgnoreUIThreadUnsafeCalls.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.guieffect; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | /** 9 | * Used to mark methods that get a free pass on calling {@link UIThreadUnsafe} methods, 10 | * despite not being marked as {@link UIThreadUnsafe} themselves. 11 | *
12 | * This is only taken into account by ArchUnit test {@code com.virtuslab.archunit.UIThreadUnsafeMethodInvocationsTestSuite} 13 | * that enforces the correct usage of {@link UIThreadUnsafe} annotation. 14 | *
15 | * Needs to be used sparingly, as this basically allows for a method to call potentially heavyweight operations on UI thread. 16 | * And that, in turn, might lead to UI freeze. 17 | *
18 | * This annotation must have runtime retention to be visible to ArchUnit tests. 19 | */ 20 | @Retention(RetentionPolicy.RUNTIME) 21 | @Target({ElementType.METHOD, ElementType.CONSTRUCTOR}) 22 | public @interface IgnoreUIThreadUnsafeCalls { 23 | /** 24 | * {@code value} must include full names (in the format as returned by 25 | * {@code com.tngtech.archunit.core.domain.AccessTarget#getFullName()}) 26 | * of UI-thread-unsafe methods that can legally be called from the annotated method. 27 | */ 28 | String[] value(); 29 | } 30 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/gitmachete/backend/api/ConfirmedLocal.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.gitmachete.backend.api; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.SubtypeOf; 9 | 10 | import com.virtuslab.qual.subtyping.internal.SubtypingTop; 11 | 12 | /** 13 | * Used to annotate a type of a {@code com.virtuslab.gitmachete.backend.api.IBranchReference} object 14 | * that has been statically proven to be a {@code com.virtuslab.gitmachete.backend.api.ILocalBranchReference}. 15 | *
16 | * See Subtyping Checker manual. 17 | */ 18 | @Retention(RetentionPolicy.CLASS) 19 | @SubtypeOf(SubtypingTop.class) 20 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 21 | public @interface ConfirmedLocal {} 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/gitmachete/backend/api/ConfirmedNonRoot.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.gitmachete.backend.api; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.SubtypeOf; 9 | 10 | import com.virtuslab.qual.subtyping.internal.SubtypingTop; 11 | 12 | /** 13 | * Used to annotate a type of a {@code com.virtuslab.gitmachete.backend.api.IManagedBranchSnapshot} object 14 | * that has been statically proven to be a {@code com.virtuslab.gitmachete.backend.api.INonRootManagedBranchSnapshot}. 15 | *
16 | * See Subtyping Checker manual. 17 | */ 18 | @Retention(RetentionPolicy.CLASS) 19 | @SubtypeOf(SubtypingTop.class) 20 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 21 | public @interface ConfirmedNonRoot {} 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/gitmachete/backend/api/ConfirmedRemote.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.gitmachete.backend.api; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.SubtypeOf; 9 | 10 | import com.virtuslab.qual.subtyping.internal.SubtypingTop; 11 | 12 | /** 13 | * Used to annotate a type of a {@code com.virtuslab.gitmachete.backend.api.IBranchReference} object 14 | * that has been statically proven to be a {@code com.virtuslab.gitmachete.backend.api.IRemoteBranchReference}. 15 | *
16 | * See Subtyping Checker manual. 17 | */ 18 | @Retention(RetentionPolicy.CLASS) 19 | @SubtypeOf(SubtypingTop.class) 20 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 21 | public @interface ConfirmedRemote {} 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/gitmachete/backend/api/ConfirmedRoot.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.gitmachete.backend.api; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.SubtypeOf; 9 | 10 | import com.virtuslab.qual.subtyping.internal.SubtypingTop; 11 | 12 | /** 13 | * Used to annotate a type of a {@code com.virtuslab.gitmachete.backend.api.IManagedBranchSnapshot} object 14 | * that has been statically proven to be a {@code com.virtuslab.gitmachete.backend.api.IRootManagedBranchSnapshot}. 15 | *
16 | * See Subtyping Checker manual. 17 | */ 18 | @Retention(RetentionPolicy.CLASS) 19 | @SubtypeOf(SubtypingTop.class) 20 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 21 | public @interface ConfirmedRoot {} 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/gitmachete/frontend/graph/api/elements/ConfirmedGraphEdge.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.gitmachete.frontend.graph.api.elements; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.SubtypeOf; 9 | 10 | import com.virtuslab.qual.subtyping.internal.SubtypingTop; 11 | 12 | /** 13 | * Used to annotate a type of a {@code com.virtuslab.gitmachete.frontend.graph.api.elements.IGraphElement} object 14 | * that has been statically proven to be a {@code com.virtuslab.gitmachete.frontend.graph.api.elements.GraphEdge}. 15 | *
16 | * See Subtyping Checker manual. 17 | */ 18 | @Retention(RetentionPolicy.CLASS) 19 | @SubtypeOf(SubtypingTop.class) 20 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 21 | public @interface ConfirmedGraphEdge {} 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/gitmachete/frontend/graph/api/elements/ConfirmedGraphNode.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.gitmachete.frontend.graph.api.elements; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.SubtypeOf; 9 | 10 | import com.virtuslab.qual.subtyping.internal.SubtypingTop; 11 | 12 | /** 13 | * Used to annotate a type of a {@code com.virtuslab.gitmachete.frontend.graph.api.elements.IGraphElement} object 14 | * that has been statically proven to be a {@code com.virtuslab.gitmachete.frontend.graph.api.elements.GraphNode}. 15 | *
16 | * See Subtyping Checker manual. 17 | */ 18 | @Retention(RetentionPolicy.CLASS) 19 | @SubtypeOf(SubtypingTop.class) 20 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 21 | public @interface ConfirmedGraphNode {} 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/gitmachete/frontend/graph/api/items/ConfirmedBranchItem.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.gitmachete.frontend.graph.api.items; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.SubtypeOf; 9 | 10 | import com.virtuslab.qual.subtyping.internal.SubtypingTop; 11 | 12 | /** 13 | * Used to annotate a type of a {@code com.virtuslab.gitmachete.frontend.graph.api.items.IBranchItem} object 14 | * that has been statically proven to be a {@code com.virtuslab.gitmachete.frontend.graph.impl.items.BranchItem}. 15 | *
16 | * See Subtyping Checker manual. 17 | */ 18 | @Retention(RetentionPolicy.CLASS) 19 | @SubtypeOf(SubtypingTop.class) 20 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 21 | public @interface ConfirmedBranchItem {} 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/gitmachete/frontend/graph/api/items/ConfirmedCommitItem.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.gitmachete.frontend.graph.api.items; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.SubtypeOf; 9 | 10 | import com.virtuslab.qual.subtyping.internal.SubtypingTop; 11 | 12 | /** 13 | * Used to annotate a type of a {@code com.virtuslab.gitmachete.frontend.graph.api.items.IBranchItem} object 14 | * that has been statically proven to be a {@code com.virtuslab.gitmachete.frontend.graph.impl.items.CommitItem}. 15 | *
16 | * See Subtyping Checker manual. 17 | */ 18 | @Retention(RetentionPolicy.CLASS) 19 | @SubtypeOf(SubtypingTop.class) 20 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 21 | public @interface ConfirmedCommitItem {} 22 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/internal/SubtypingTop.java: -------------------------------------------------------------------------------- 1 | package com.virtuslab.qual.subtyping.internal; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import org.checkerframework.framework.qual.DefaultQualifierInHierarchy; 9 | import org.checkerframework.framework.qual.SubtypeOf; 10 | 11 | /** 12 | * There needs to be single subtyping hierarchy with single bottom and top annotation. 13 | * We could theoretically create a separate hierarchy with a dedicated top and bottom type 14 | * for each pair of annotations from {@link com.virtuslab.qual.subtyping}.* packages, 15 | * but then Subtyping Checker 16 | * would raise an error about multiple top/bottom types. 17 | */ 18 | @DefaultQualifierInHierarchy 19 | @Retention(RetentionPolicy.CLASS) 20 | @SubtypeOf({}) 21 | @Target({ElementType.TYPE_USE, ElementType.TYPE_PARAMETER}) 22 | public @interface SubtypingTop {} 23 | -------------------------------------------------------------------------------- /qual/src/main/java/com/virtuslab/qual/subtyping/internal/package-info.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Module private. Do not use outside {@link com.virtuslab.qual.subtyping}. 3 | */ 4 | package com.virtuslab.qual.subtyping.internal; 5 | -------------------------------------------------------------------------------- /scalafmt.conf: -------------------------------------------------------------------------------- 1 | version = 3.5.9 2 | runner.dialect = scala213 3 | maxColumn = 120 4 | -------------------------------------------------------------------------------- /scripts/close-github-milestone: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e -o pipefail -u -x 4 | 5 | milestone_title=$1 6 | 7 | milestones_json_array=$(gh api repos/VirtusLab/git-machete-intellij-plugin/milestones) 8 | milestone=$(echo "$milestones_json_array" | jq -c --arg TITLE "$milestone_title" '.[] | select(.title == $TITLE)') 9 | 10 | number=$(echo "$milestone" | jq '.number') 11 | # open issues and PRs are counted together in the same field 12 | open_issue_count=$(echo "$milestone" | jq '.open_issues') 13 | 14 | if [[ $open_issue_count = 0 ]]; then 15 | gh api --method PATCH "repos/VirtusLab/git-machete-intellij-plugin/milestones/$number" -f state=closed 16 | fi 17 | -------------------------------------------------------------------------------- /scripts/enforce-astub-explicit-annotation-import: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e -o pipefail -u 4 | 5 | self_dir=$(cd "$(dirname "$0")" &>/dev/null; pwd -P) 6 | source "$self_dir"/utils.sh 7 | 8 | exit_code=0 9 | 10 | for file in $(git ls-files '*.astub'); do 11 | annotations_imported_in_file=$(grep -Po '(?<=import ).*(?=;)' "$file" | rev | cut -d. -f1 | rev | sort -u) 12 | annotations_used_across_file=$(grep -Po '(?<=@)[a-zA-Z0-9.]*' "$file" | sort -u) 13 | 14 | # Print the lines missing from the first input but present in the second 15 | unimported_annotations=$(comm -13 <(echo "$annotations_imported_in_file") <(echo "$annotations_used_across_file")) 16 | if [[ $unimported_annotations ]]; then 17 | echo "$file: $(echo -n "$unimported_annotations" | tr '\n' ',' | sed 's/,/, /g') must be imported explicitly" 18 | exit_code=1 19 | fi 20 | 21 | # Print the lines present in the first input but missing from the second 22 | unused_annotations=$(comm -23 <(echo "$annotations_imported_in_file") <(echo "$annotations_used_across_file")) 23 | if [[ $unused_annotations ]]; then 24 | echo "$file: $(echo -n "$unused_annotations" | tr '\n' ',' | sed 's/,/, /g') imported but unused" 25 | exit_code=1 26 | fi 27 | done 28 | 29 | exit $exit_code 30 | -------------------------------------------------------------------------------- /scripts/enforce-change-notes-updated-on-pr-to-master: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e -o pipefail -u 4 | 5 | self_dir=$(cd "$(dirname "$0")" &>/dev/null; pwd -P) 6 | source "$self_dir"/utils.sh 7 | 8 | if [[ ${CI_PULL_REQUEST-} && ${GITHUB_TOKEN-} ]]; then 9 | # In case of a PR build, CI_PULL_REQUEST should be a link of the form https://github.com/VirtusLab/git-machete-intellij-plugin/pull/123 10 | pr_num=${CI_PULL_REQUEST##*/} 11 | # Implicit usage of ${GITHUB_TOKEN} by gh 12 | base_branch=$(gh pr view "$pr_num" --json "baseRefName") 13 | 14 | # PRs to master are typically either release or hotfix PRs, both of which should have change notes updated 15 | if [[ $base_branch == master ]]; then 16 | ./gradlew -q verifyChangeLogContents 17 | fi 18 | fi 19 | -------------------------------------------------------------------------------- /scripts/enforce-indent-two-spaces-outside-java: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e -o pipefail -u 4 | 5 | self_dir=$(cd "$(dirname "$0")" &>/dev/null; pwd -P) 6 | self_name=$(basename -s .sh "$0") 7 | 8 | git ls-files \ 9 | ':!*.flex' ':!gradlew' ':!*.java' ':!*.kt' ':!*.md' \ 10 | ':!plugin-verifier.gradle' '!*.scala' ':!scripts/setup-multiroot-sandbox' \ 11 | ':!*.svg' ':!testCommon/src/test/resources/*.sh' ':!*.xml' \ 12 | | xargs awk -f "$self_dir/$self_name.awk" 13 | -------------------------------------------------------------------------------- /scripts/enforce-indent-two-spaces-outside-java.awk: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env awk 2 | 3 | FNR == 1 { prev_non_empty = "" } 4 | 5 | ( /^ {3}/ && prev_non_empty !~ /^ {2}/ ) || ( /^ {5}/ && prev_non_empty !~ /^ {4}/ ) { 6 | print FILENAME ":" FNR ": likely three or four spaces used for indent instead of two" 7 | exit_code = 1 8 | } 9 | 10 | /^.+$/ { prev_non_empty = $0 } 11 | 12 | END { exit exit_code } 13 | -------------------------------------------------------------------------------- /scripts/enforce-issue-number-for-todos: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e -o pipefail -u 4 | 5 | self_dir=$(cd "$(dirname "$0")" &>/dev/null; pwd -P) 6 | source "$self_dir"/utils.sh 7 | 8 | # Negative lookahead (?!...), requires Perl syntax (-P): find fixmes/todos NOT followed by issue number 9 | if git grep -PIin '(\*|//|#|