Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
42,800 | boolean (@NotNull GitVersion version) { return Registry.is("git.can.use.restore.command") && version.isLaterOrEqual(new GitVersion(2, 25, 1, 0)); } | existsIn |
42,801 | boolean (@NotNull GitVersion version) { return version.isLaterOrEqual(new GitVersion(2, 24, 0, 0)); } | existsIn |
42,802 | boolean (@NotNull GitVersion version) { return version.isLaterOrEqual(new GitVersion(2, 32, 0, 0)); } | existsIn |
42,803 | boolean (@NotNull GitVersion version) { return version.isLaterOrEqual(new GitVersion(2, 31, 0, 0)); } | existsIn |
42,804 | boolean (@NotNull GitVersion version) { return version.isLaterOrEqual(new GitVersion(2, 34, 0, 0)); } | existsIn |
42,805 | boolean (@NotNull GitVersion version) { return version.isLaterOrEqual(new GitVersion(2, 36, 0, 0)); } | existsIn |
42,806 | boolean (@NotNull GitVersion version) { return version.isLaterOrEqual(new GitVersion(2, 13, 0, 0)); } | existsIn |
42,807 | boolean (@NotNull GitVersion version) { return version.isLaterOrEqual(new GitVersion(2, 26, 0, 0)); } | existsIn |
42,808 | boolean (@NotNull Project project) { GitVersion version = GitExecutableManager.getInstance().tryGetVersion(project); return existsIn(Objects.requireNonNullElse(version, GitVersion.NULL)); } | existsIn |
42,809 | boolean (@Nullable Project project, @NotNull GitExecutable executable) { GitVersion version = GitExecutableManager.getInstance().tryGetVersion(project, executable); return existsIn(Objects.requireNonNullElse(version, GitVersion.NULL)); } | existsIn |
42,810 | boolean (@NotNull GitRepository repository) { return existsIn(repository.getProject()); } | existsIn |
42,811 | boolean (@NotNull AbstractVcs vcs) { return existsIn(vcs.getProject()); } | existsIn |
42,812 | State () { State s = new State(); s.setLastSuccessful(new TreeMap<>(myLastSuccessful)); return s; } | getState |
42,813 | void (@NotNull State state) { myLastSuccessful.clear(); myLastSuccessful.putAll(state.getLastSuccessful()); } | loadState |
42,814 | void (@NonNls String userName, @NonNls String method) { if (null == method || method.length() == 0) { myLastSuccessful.remove(userName); } else { myLastSuccessful.put(userName, method); } } | setLastSuccessful |
42,815 | SSHConnectionSettings () { return ApplicationManager.getApplication().getService(SSHConnectionSettings.class); } | getInstance |
42,816 | void (Map<String, String> map) { myLastSuccessful = map; } | setLastSuccessful |
42,817 | String (@Nullable WSLDistribution distribution) { List<Detector> detectors = collectDetectors(distribution); String detectedPath = getExecutable(detectors); if (detectedPath != null) return detectedPath; return runUnderProgressIfNeeded(null, GitBundle.message("git.executable.detect.progress.title"), () -> detectExecuta... | detect |
42,818 | String (@NotNull List<Detector> detectors) { String path = null; boolean fireEvent = false; synchronized (DETECTED_EXECUTABLE_LOCK) { for (Detector detector : detectors) { DetectedPath detectedPath = detector.getPath(); if (detectedPath == null) { detector.runDetection(); fireEvent = true; detectedPath = detector.getPa... | detectExecutable |
42,819 | void () { synchronized (DETECTED_EXECUTABLE_LOCK) { myEnvExecutable.set(null); mySystemExecutable.set(null); myWslExecutables.clear(); myWslDistributionsProcessed = false; } ApplicationManager.getApplication().getMessageBus().syncPublisher(GitExecutableManager.TOPIC).executableChanged(); } | clear |
42,820 | List<Detector> (@Nullable WSLDistribution projectWslDistribution) { List<Detector> detectors = new ArrayList<>(); if (projectWslDistribution != null && GitExecutableManager.supportWslExecutable()) { detectors.add(new WslDetector(projectWslDistribution)); } detectors.add(new EnvDetector()); detectors.add(new SystemPathD... | collectDetectors |
42,821 | void () { File executableFromEnv = PathEnvironmentVariableUtil.findInPath(SystemInfo.isWindows ? WIN_EXECUTABLE : UNIX_EXECUTABLE, getPathEnv(), null); String path = executableFromEnv != null ? executableFromEnv.getAbsolutePath() : null; myEnvExecutable.set(new DetectedPath(path)); } | runDetection |
42,822 | void () { String executable = SystemInfo.isWindows ? detectForWindows() : detectForUnix(); mySystemExecutable.set(new DetectedPath(executable)); } | runDetection |
42,823 | void () { String result = checkWslDistributionSafe(myDistribution); myWslExecutables.put(myDistribution, new DetectedPath(result)); } | runDetection |
42,824 | void () { List<WSLDistribution> distributions = WslDistributionManager.getInstance().getInstalledDistributions(); for (WSLDistribution distribution : distributions) { String result = checkWslDistributionSafe(distribution); myWslExecutables.put(distribution, new DetectedPath(result)); } myWslDistributionsProcessed = tru... | runDetection |
42,825 | String () { return SystemInfo.isWindows ? WIN_EXECUTABLE : UNIX_EXECUTABLE; } | getDefaultExecutable |
42,826 | String (@NotNull WSLDistribution distribution) { Future<String> future = myWslExecutor.submit(() -> checkWslDistribution(distribution)); try { return future.get(WSL_DETECTION_TIMEOUT_MS, TimeUnit.MILLISECONDS); } catch (InterruptedException | ExecutionException | TimeoutException e) { LOG.warn(String.format("WSL execut... | checkWslDistributionSafe |
42,827 | File () { return WIN_ROOT; } | getWinRoot |
42,828 | int (File f1, File f2) { String name1 = StringUtil.toLowerCase(f1.getName()); String name2 = StringUtil.toLowerCase(f2.getName()); // C:\Program Files\Git is better candidate for _default_ than C:\Program Files\Git_1.8.0 if (name1.equals("git")) { return name2.equals("git") ? fallback(f1, f2) : 1; } else if (name2.equa... | compare |
42,829 | int (@NotNull File f1, @NotNull File f2) { // "Program Files" is preferable over "Program Files (x86)" int compareParents = f1.getParentFile().getName().compareTo(f2.getParentFile().getName()); if (compareParents != 0) { return -compareParents; // greater is better => reversing } // probably some unrecognized format of... | fallback |
42,830 | int (String group) { return group == null ? 0 : Integer.parseInt(group); } | parseOrNull |
42,831 | String () { GitExecutable executable = GitExecutableManager.getInstance().getExecutable(myProject); if (executable instanceof GitExecutable.Local) return executable.getExePath(); return ""; } | getCurrentExecutable |
42,832 | String () { return GitBundle.message("settings.git.option.group"); } | getConfigurableDisplayName |
42,833 | boolean (@NotNull String pathToGit) { try { GitExecutable.Local executable = new GitExecutable.Local(pathToGit); GitVersion version = GitExecutableManager.getInstance().identifyVersion(executable); return !GitVersion.NULL.equals(version); } catch (GitVersionIdentificationException e) { return false; } } | isExecutableValid |
42,834 | void (@NotNull State state) { myState = state; } | loadState |
42,835 | GitSharedSettings (@NotNull Project project) { return project.getService(GitSharedSettings.class); } | getInstance |
42,836 | boolean () { return myState.synchronizeBranchProtectionRules; } | isSynchronizeBranchProtectionRules |
42,837 | void (boolean sync) { myState.synchronizeBranchProtectionRules = sync; } | setSynchronizeBranchProtectionRules |
42,838 | List<String> () { return Collections.unmodifiableList(myState.FORCE_PUSH_PROHIBITED_PATTERNS); } | getForcePushProhibitedPatterns |
42,839 | void (@NotNull List<String> patterns) { myState.FORCE_PUSH_PROHIBITED_PATTERNS = new ArrayList<>(patterns); } | setForcePushProhibitedPatterns |
42,840 | boolean (@NotNull String branch) { // let "master" match only "master" and not "any-master-here" by default return Stream.of(getForcePushProhibitedPatterns(), getAdditionalProhibitedPatterns()) .flatMap(Collection::stream) .anyMatch(pattern -> isMatchSafe(branch, pattern)); } | isBranchProtected |
42,841 | boolean (@NotNull String branch, @NotNull String pattern) { try { return branch.matches("^" + pattern + "$"); } catch (PatternSyntaxException e) { if (LOG.isDebugEnabled()) { String cause = StringUtil.substringBefore(e.getMessage(), "\n"); LOG.debug(GitBundle.message("settings.protected.branched.validation", pattern, c... | isMatchSafe |
42,842 | List<String> () { if (!isSynchronizeBranchProtectionRules()) return Collections.emptyList(); return GitProtectedBranchProvider.getProtectedBranchPatterns(myProject); } | getAdditionalProhibitedPatterns |
42,843 | GitExecutableProblemsNotifier (@NotNull Project project) { return project.getService(GitExecutableProblemsNotifier.class); } | getInstance |
42,844 | void (@NotNull Throwable exception) { GitExecutableProblemHandler problemHandler = findGitExecutableProblemHandler(myProject); ErrorNotifier errorNotifier = new NotificationErrorNotifier(myProject); problemHandler.showError(exception, errorNotifier); } | notifyExecutionError |
42,845 | void (@NotNull Project project, @NotNull BadGitExecutableNotification notification) { ModalityUiUtil.invokeLaterIfNeeded(ModalityState.defaultModalityState(), () -> { if (ensureSingularOfType(project, notification.getClass())) { notification.notify(project); } }); } | notify |
42,846 | boolean (@NotNull Project project, @NotNull Class<? extends BadGitExecutableNotification> notificationType) { BadGitExecutableNotification[] currentNotifications = getNotificationsManager().getNotificationsOfType(BadGitExecutableNotification.class, project); int notificationsCount = currentNotifications.length; if (not... | ensureSingularOfType |
42,847 | void () { for (BadGitExecutableNotification notification : getNotificationsManager() .getNotificationsOfType(BadGitExecutableNotification.class, myProject)) { notification.expire(); } } | expireNotifications |
42,848 | int (@NotNull Matcher matcher, int group) { if (group > matcher.groupCount() + 1) { return 0; } final String match = matcher.group(group); if (match == null) { return 0; } return Integer.parseInt(match); } | getIntGroup |
42,849 | String (@NotNull Matcher matcher, int group) { if (group > matcher.groupCount() + 1) { return ""; } final String match = matcher.group(group); if (match == null) { return ""; } return match.trim(); } | getStringGroup |
42,850 | boolean () { Type type = getType(); return type != Type.NULL && (Registry.is("git.allow.wsl1.executables") || type != Type.WSL1) && compareTo(MIN) >= 0; } | isSupported |
42,851 | boolean (Object obj) { if (!(obj instanceof GitVersion other)) { return false; } if (compareTo(other) != 0) { return false; } if (myType == Type.UNDEFINED || other.myType == Type.UNDEFINED) { return true; } return myType == other.myType; } | equals |
42,852 | int () { return myHashCode; } | hashCode |
42,853 | int (@NotNull GitVersion o) { if (o.getType() == Type.NULL) { return (getType() == Type.NULL ? 0 : 1); } int d = myMajor - o.myMajor; if (d != 0) { return d; } d = myMinor - o.myMinor; if (d != 0) { return d; } d = myRevision - o.myRevision; if (d != 0) { return d; } return myPatchLevel - o.myPatchLevel; } | compareTo |
42,854 | String () { String presentation = myMajor + "." + myMinor + "." + myRevision; if (myPatchLevel > 0) presentation += "." + myPatchLevel; return presentation; } | getPresentation |
42,855 | String () { return myMajor + "." + myMinor + "." + myRevision + "." + myPatchLevel + " (" + myType + ")"; } | toString |
42,856 | String () { String presentation = myMajor + "." + myMinor + "." + myRevision; if (myPatchLevel > 0) presentation += "." + myPatchLevel; return presentation + "-" + myType; } | getSemanticPresentation |
42,857 | boolean (final GitVersion gitVersion) { return gitVersion != null && compareTo(gitVersion) <= 0; } | isOlderOrEqual |
42,858 | boolean (GitVersion version) { return version != null && compareTo(version) >= 0; } | isLaterOrEqual |
42,859 | Type () { return myType; } | getType |
42,860 | boolean () { return getType() == Type.NULL; } | isNull |
42,861 | boolean () { return switch (getType()) { case WSL1, WSL2 -> true; default -> false; }; } | isWSL |
42,862 | GitVcsApplicationSettings () { return GitVcsApplicationSettings.getInstance(); } | getAppSettings |
42,863 | GitVcsSettings (Project project) { return project.getService(GitVcsSettings.class); } | getInstance |
42,864 | UpdateMethod () { return getState().getUpdateMethod(); } | getUpdateMethod |
42,865 | void (UpdateMethod updateType) { getState().setUpdateMethod(updateType); } | setUpdateMethod |
42,866 | GitSaveChangesPolicy () { return getState().getSaveChangesPolicy(); } | getSaveChangesPolicy |
42,867 | void (GitSaveChangesPolicy value) { getState().setSaveChangesPolicy(value); } | setSaveChangesPolicy |
42,868 | void (@NotNull VcsUser author) { List<String> previousCommitAuthors = getState().getPreviousCommitAuthors(); previousCommitAuthors.remove(author.toString()); while (previousCommitAuthors.size() >= PREVIOUS_COMMIT_AUTHORS_LIMIT) { previousCommitAuthors.remove(previousCommitAuthors.size() - 1); } previousCommitAuthors.ad... | saveCommitAuthor |
42,869 | String[] () { return ArrayUtilRt.toStringArray(getState().getPreviousCommitAuthors()); } | getCommitAuthors |
42,870 | void (@NotNull GitVcsOptions state) { super.loadState(state); migrateUpdateIncomingBranchInfo(state); } | loadState |
42,871 | void (@NotNull GitVcsOptions state) { if (!state.isUpdateBranchesInfo()) { state.setIncomingCheckStrategy(GitIncomingCheckStrategy.Never); //set default value state.setUpdateBranchesInfo(true); } } | migrateUpdateIncomingBranchInfo |
42,872 | void (@Nullable String value) { getState().setPathToGit(value); ApplicationManager.getApplication().getMessageBus().syncPublisher(GitExecutableManager.TOPIC).executableChanged(); } | setPathToGit |
42,873 | boolean () { return getState().isPushAutoUpdate(); } | autoUpdateIfPushRejected |
42,874 | void (boolean value) { getState().setPushAutoUpdate(value); } | setAutoUpdateIfPushRejected |
42,875 | Value () { return getState().getRootSync(); } | getSyncSetting |
42,876 | void (@NotNull Value value) { getState().setRootSync(value); } | setSyncSetting |
42,877 | void (@NotNull String value) { getState().setRecentGitRootPath(value); } | setRecentRoot |
42,878 | void (@NotNull String repositoryPath, @NotNull String branch) { getState().getRecentBranchByRepository().put(repositoryPath, branch); } | setRecentBranchOfRepository |
42,879 | void (@NotNull String value) { getState().setRecentCommonBranch(value); } | setRecentCommonBranch |
42,880 | boolean () { return getState().getShowRecentBranches(); } | showRecentBranches |
42,881 | void (boolean value) { getState().setShowRecentBranches(value); } | setShowRecentBranches |
42,882 | boolean () { return getState().getWarnAboutCrlf(); } | warnAboutCrlf |
42,883 | void (boolean value) { getState().setWarnAboutCrlf(value); } | setWarnAboutCrlf |
42,884 | boolean () { return getState().isWarnAboutDetachedHead(); } | warnAboutDetachedHead |
42,885 | void (boolean value) { getState().setWarnAboutDetachedHead(value); } | setWarnAboutDetachedHead |
42,886 | void (@NotNull GitResetMode mode) { getState().setResetMode(mode); } | setResetMode |
42,887 | void (@Nullable GitPushTagMode value) { getState().setPushTags(value); } | setPushTagMode |
42,888 | boolean () { return getState().isSignOffCommit(); } | shouldSignOffCommit |
42,889 | void (boolean value) { getState().setSignOffCommit(value); } | setSignOffCommit |
42,890 | GitIncomingCheckStrategy () { return getState().getIncomingCheckStrategy(); } | getIncomingCheckStrategy |
42,891 | void (@NotNull GitIncomingCheckStrategy strategy) { getState().setIncomingCheckStrategy(strategy); } | setIncomingCheckStrategy |
42,892 | boolean () { return getState().isPreviewPushOnCommitAndPush(); } | shouldPreviewPushOnCommitAndPush |
42,893 | void (boolean value) { getState().setPreviewPushOnCommitAndPush(value); } | setPreviewPushOnCommitAndPush |
42,894 | boolean () { return getState().isPreviewPushProtectedOnly(); } | isPreviewPushProtectedOnly |
42,895 | void (boolean value) { getState().setPreviewPushProtectedOnly(value); } | setPreviewPushProtectedOnly |
42,896 | boolean () { return getState().isCommitRenamesSeparately(); } | isCommitRenamesSeparately |
42,897 | void (boolean value) { getState().setCommitRenamesSeparately(value); } | setCommitRenamesSeparately |
42,898 | DvcsBranchSettings () { return getState().getBranchSettings(); } | getBranchSettings |
42,899 | boolean () { return getState().isSetUserNameGlobally(); } | shouldSetUserNameGlobally |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.