Class AppSettings
java.lang.Object
io.github.jbastgen.stemma.app.config.AppSettings
The global settings that the settings dialog edits (everything except look and layout, see
ViewSettings).
A plain mutable object: the dialog works on a copy() and hands it back on Save.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumHow merge conflicts are resolved.static final recordResult of reading the extra-configuration text. -
Field Summary
FieldsModifier and TypeFieldDescriptionbooleanThe account (Settings → Accounts) holding the API key.booleanFeature 5: write changelog entries with the AI.Command line of the GitHub Copilot command line tool;$PROMPTis the prompt.booleanThe tab "Cowork" of a repository: talk to the AI about it.booleanbooleanFeature 28: ask the AI for labels by itself while files are selected for the commit (sends file names without a click).booleanEstimate the labels of commits with AI (context menu of commits).booleanbooleanWrite everything that is sent to an AI service to the AI log file (seeAiLog).intintbooleanFeature 6: propose the resolution of merge conflicts with the AI.booleanFeature 4: suggest messages for staged changes.booleanintbooleanFeature 3: describe the selected commits with AI.intWorking folder of the local AI tool; empty (the default),.or./= the repository the request is about.booleanFeature 7: translate commit messages with the AI.booleanAlso offer a plain force push (without the lease that protects other people's work).booleanFeature 54: fetch from the remotes of the open repositories by itself (off by default).booleanAlso fetch while the window is in the background (by default only while it is the active window).intMinutes between two automatic fetches of a repository.Language of the commit, merge and tag messages the AI suggests (English name); empty = the language of the recent commit messages.Template for new commit messages, seeMessageTemplates; empty = none.booleanAsk before amending a commit that is already on the upstream branch (it will need a force push).booleanAsk before files are discarded or deleted from the commit panel (conflicted files and the toolbar button always ask).booleanFeature 45: ask once more before a hard reset throws changes away (the dialog that picks the kind of reset always appears).booleanMove untracked files that are deleted to the operating system's trash, where there is one.Command line of the external merge tool;$BASE $LOCAL $REMOTE $MERGEDare replaced.booleanFetch removes remote-tracking branches that are gone from the remote (feature 22).Command line that replaces the platform's way;$DIRand$FILEare replaced.booleanFeature 10: the "Show in Explorer / Finder / Files" button and the "Show in file manager" entry of a file.booleanThe settings dialog was shown at the first start.Further git configuration, onesection.name=valueper line.booleanFeature 59: pictures and profile pages of the authors from GitHub (preferred over Gravatar).Author for commits when neither the repository nor the user's git configuration names one.booleanFeature 59: pictures and profile pages of the authors from Gravatar.Where "Ignore" from the menu of a file writes to:gitignore(shared) orexclude(only this clone).booleanFeature 25/28: propose labels in the commit form from the branch name and the files, without AI (the rules ofLabelHints).booleanCommit labels (feature, bugfix, …) on or off.The label index file; empty =labels.tsvin the configuration folder.Feature 9: the language of the interface: a code ofi18n/languages.tsv, or empty for the language of the system.How much is written to the log file: info, debug or trace (seeLogLevel).Template for the message of a merge commit; empty = git's own message.booleanOffer "Force push (with lease)" after a rejected push and in the menu of the Push button.booleanFeature 12: the entry "Open" in the menu of a file (opens it with the system's program).booleanFill the commit form with the template when it is empty.Folder that clone / create / open start in; empty = the home folder.io.github.jbastgen.stemma.git.api.GitOptions.ProxyModebooleanPush the tags together with a branch that is pushed.booleanFeature 53: refresh the open repository when files change on disk or another tool changes it, not only when the window gets the focus.booleanReload the open repository when the window gets the focus again (another tool may have changed it).Servers of your own: onehost = serviceper line (github, gitlab, bitbucket, azure, gitea).booleanFeature 14: the entries that open the commit, branch, file or repository on the hosting service of the remote.booleanFeature 45: before a hard reset keep the working tree and the old branch tip underrefs/stemma/reset/….booleanFeature 19: the small "Buy me a coffee" link in the status bar and in the About dialog.booleanFeature 52: the Files view shows source files in the colours of their language.Command line that replaces the choice above;$DIRis the repository's folder.booleanFeature 11: the "Terminal" toolbar button that opens a terminal in the repository.Which terminal:auto(the first one installed) or the key of one (seeTerminalLauncher.Terminal).Feature 13: programs for the entry "Open in …" of a file, one per line (seeExternalTools).The language last chosen for translating commit messages (English name).Feature 7: languages whose messages are not translated (names separated by commas): by default English and the language of the interface.booleanFeature 26: show several identities of one person as one user, as the user mapping file says.The user mapping file; empty =users.tsvin the configuration folder.boolean -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncopy()A copy to edit; the settings dialog works on a copy and the application takes it over on OK.static AppSettings.ParsedConfigparseExtraConfig(String text) Readskey=valuelines; blank lines and lines starting with#are ignored.The AI settings as the connection uses them; numbers are kept within sensible limits.io.github.jbastgen.stemma.git.api.GitOptionsThe part of the settings the Git backends need.io.github.jbastgen.stemma.git.api.GitOptionstoGitOptions(io.github.jbastgen.stemma.git.api.CredentialLookup credentials, Path askpass, Path sshDirectory) AstoGitOptions(), plus where credentials come from and where the built-in Git keeps SSH host keys.
-
Field Details
-
firstStartDone
public boolean firstStartDoneThe settings dialog was shown at the first start. Deleting the settings file brings the welcome back. -
projectDir
Folder that clone / create / open start in; empty = the home folder. -
reloadOnFocus
public boolean reloadOnFocusReload the open repository when the window gets the focus again (another tool may have changed it). -
refreshOnChange
public boolean refreshOnChangeFeature 53: refresh the open repository when files change on disk or another tool changes it, not only when the window gets the focus. -
logLevel
How much is written to the log file: info, debug or trace (seeLogLevel). -
supportLinkEnabled
public boolean supportLinkEnabledFeature 19: the small "Buy me a coffee" link in the status bar and in the About dialog. -
gravatarEnabled
public boolean gravatarEnabledFeature 59: pictures and profile pages of the authors from Gravatar. Off: a request carries the hash of an author's e-mail address to gravatar.com. -
syntaxHighlighting
public boolean syntaxHighlightingFeature 52: the Files view shows source files in the colours of their language. -
githubPicturesEnabled
public boolean githubPicturesEnabledFeature 59: pictures and profile pages of the authors from GitHub (preferred over Gravatar). Off: a request names a commit of the GitHub repository. -
confirmDiscard
public boolean confirmDiscardAsk before files are discarded or deleted from the commit panel (conflicted files and the toolbar button always ask). -
discardToTrash
public boolean discardToTrashMove untracked files that are deleted to the operating system's trash, where there is one. -
fetchPrune
public boolean fetchPruneFetch removes remote-tracking branches that are gone from the remote (feature 22). -
autoFetch
public boolean autoFetchFeature 54: fetch from the remotes of the open repositories by itself (off by default). -
autoFetchMinutes
public int autoFetchMinutesMinutes between two automatic fetches of a repository. -
autoFetchInBackground
public boolean autoFetchInBackgroundAlso fetch while the window is in the background (by default only while it is the active window). -
confirmAmendPublished
public boolean confirmAmendPublishedAsk before amending a commit that is already on the upstream branch (it will need a force push). -
confirmReset
public boolean confirmResetFeature 45: ask once more before a hard reset throws changes away (the dialog that picks the kind of reset always appears). -
resetBackup
public boolean resetBackupFeature 45: before a hard reset keep the working tree and the old branch tip underrefs/stemma/reset/…. -
offerForcePush
public boolean offerForcePushOffer "Force push (with lease)" after a rejected push and in the menu of the Push button. -
allowPlainForce
public boolean allowPlainForceAlso offer a plain force push (without the lease that protects other people's work). -
pushTagsWithBranch
public boolean pushTagsWithBranchPush the tags together with a branch that is pushed. -
ignoreTarget
Where "Ignore" from the menu of a file writes to:gitignore(shared) orexclude(only this clone). -
backend
-
gitUserName
Author for commits when neither the repository nor the user's git configuration names one. -
gitUserEmail
-
gitExtraConfig
Further git configuration, onesection.name=valueper line. -
commitTemplate
Template for new commit messages, seeMessageTemplates; empty = none. -
mergeTemplate
Template for the message of a merge commit; empty = git's own message. -
prefillCommit
public boolean prefillCommitFill the commit form with the template when it is empty. -
labelsEnabled
public boolean labelsEnabledCommit labels (feature, bugfix, …) on or off. -
labelsIndexFile
The label index file; empty =labels.tsvin the configuration folder. Point it at a shared folder to share labels. -
language
Feature 9: the language of the interface: a code ofi18n/languages.tsv, or empty for the language of the system. -
usersEnabled
public boolean usersEnabledFeature 26: show several identities of one person as one user, as the user mapping file says. -
usersFile
The user mapping file; empty =users.tsvin the configuration folder. -
fileManagerEnabled
public boolean fileManagerEnabledFeature 10: the "Show in Explorer / Finder / Files" button and the "Show in file manager" entry of a file. -
fileManagerCommand
Command line that replaces the platform's way;$DIRand$FILEare replaced. Empty = the platform's way. -
tools
Feature 13: programs for the entry "Open in …" of a file, one per line (seeExternalTools). -
remoteLinksEnabled
public boolean remoteLinksEnabledFeature 14: the entries that open the commit, branch, file or repository on the hosting service of the remote. -
remoteHosts
Servers of your own: onehost = serviceper line (github, gitlab, bitbucket, azure, gitea). -
openFileEnabled
public boolean openFileEnabledFeature 12: the entry "Open" in the menu of a file (opens it with the system's program). -
terminalEnabled
public boolean terminalEnabledFeature 11: the "Terminal" toolbar button that opens a terminal in the repository. -
terminalProgram
Which terminal:auto(the first one installed) or the key of one (seeTerminalLauncher.Terminal). -
terminalCommand
Command line that replaces the choice above;$DIRis the repository's folder. Empty = use the choice. -
aiEnabled
public boolean aiEnabled -
aiSummaryEnabled
public boolean aiSummaryEnabledFeature 3: describe the selected commits with AI. Only has an effect whileaiEnabledis on. -
aiMessagesEnabled
public boolean aiMessagesEnabledFeature 4: suggest messages for staged changes. Only has an effect whileaiEnabledis on. -
aiLabelsEnabled
public boolean aiLabelsEnabledEstimate the labels of commits with AI (context menu of commits). Only has an effect whileaiEnabledis on. -
aiTranslateEnabled
public boolean aiTranslateEnabledFeature 7: translate commit messages with the AI. -
translateSkipLanguages
Feature 7: languages whose messages are not translated (names separated by commas): by default English and the language of the interface. -
commitMessageLanguage
Language of the commit, merge and tag messages the AI suggests (English name); empty = the language of the recent commit messages. -
aiChangelogEnabled
public boolean aiChangelogEnabledFeature 5: write changelog entries with the AI. -
aiCoworkEnabled
public boolean aiCoworkEnabledThe tab "Cowork" of a repository: talk to the AI about it. Only has an effect whileaiEnabledis on and the connection is set up. -
aiMergeEnabled
public boolean aiMergeEnabledFeature 6: propose the resolution of merge conflicts with the AI. -
translateLanguage
The language last chosen for translating commit messages (English name). -
labelHintsEnabled
public boolean labelHintsEnabledFeature 25/28: propose labels in the commit form from the branch name and the files, without AI (the rules ofLabelHints). -
aiLabelPreselect
public boolean aiLabelPreselectFeature 28: ask the AI for labels by itself while files are selected for the commit (sends file names without a click). -
aiLogEnabled
public boolean aiLogEnabledWrite everything that is sent to an AI service to the AI log file (seeAiLog). -
aiProvider
-
aiEndpoint
-
aiModel
-
aiAccountId
The account (Settings → Accounts) holding the API key. -
aiMaxPromptChars
public int aiMaxPromptChars -
aiMaxTokens
public int aiMaxTokens -
aiTimeoutSeconds
public int aiTimeoutSeconds -
aiRetries
public int aiRetries -
aiLocalOnly
public boolean aiLocalOnly -
aiExcludePatterns
-
aiRedactSecrets
public boolean aiRedactSecrets -
aiToolCommand
-
aiToolWorkDir
Working folder of the local AI tool; empty (the default),.or./= the repository the request is about. -
aiCopilotCommand
Command line of the GitHub Copilot command line tool;$PROMPTis the prompt. -
aiCustomHeaders
-
aiCustomBody
-
aiCustomAnswerPath
-
mergeTool
-
externalMergeCommand
Command line of the external merge tool;$BASE $LOCAL $REMOTE $MERGEDare replaced. -
proxyMode
public io.github.jbastgen.stemma.git.api.GitOptions.ProxyMode proxyMode -
proxyUrl
-
noProxy
-
verifySsl
public boolean verifySsl -
caBundle
-
acceptNewSshHosts
public boolean acceptNewSshHosts
-
-
Constructor Details
-
AppSettings
public AppSettings()
-
-
Method Details
-
copy
A copy to edit; the settings dialog works on a copy and the application takes it over on OK. -
toGitOptions
public io.github.jbastgen.stemma.git.api.GitOptions toGitOptions()The part of the settings the Git backends need. Lines that are not valid configuration are skipped. -
toGitOptions
public io.github.jbastgen.stemma.git.api.GitOptions toGitOptions(io.github.jbastgen.stemma.git.api.CredentialLookup credentials, Path askpass, Path sshDirectory) AstoGitOptions(), plus where credentials come from and where the built-in Git keeps SSH host keys. -
toAiConfig
The AI settings as the connection uses them; numbers are kept within sensible limits. -
parseExtraConfig
Readskey=valuelines; blank lines and lines starting with#are ignored.
-