Enum VcsType

    • Enum Constant Detail

      • GIT

        public static final VcsType GIT
    • Method Detail

      • values

        public static VcsType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (VcsType c : VcsType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static VcsType valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • mainBranch

        public String mainBranch()
        Get the name of the main, default branch of the repository.
      • listCommitsCommand

        public String listCommitsCommand​(String branch)
        Command which will list all commits for the VCS repository in a format that can be later accepted by extractCommitInfo(String). Newest commits should come first. Should work on a bare repository.
      • listBranchesCommand

        public String listBranchesCommand()
        Command which will list all branches defined in the repository. Should work on a bare repository.
      • listTagsCommand

        public String listTagsCommand()
        Command which will list all tags defined in the repository. Should work on a bare repository.
      • checkoutRevisionCommand

        public String checkoutRevisionCommand​(String revision)
        Command which will checkout the specified revision. Will only be executed on a working copy of the repository.
      • pullCommand

        public String pullCommand()
        Command to pull most recent changes from a remote. Will only be executed on a working copy of the repository.
      • createBranchCommand

        public String createBranchCommand​(String branch)
        Command to create a new branch. Will only be executed on a working copy of the repository.
      • stageChangesCommand

        public String stageChangesCommand​(String path)
        Command to stage specified changes (add/remove tracked files) for committing. Will only be executed on a working copy of the repository.