Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BudgetMaster
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Robert Goldmann
BudgetMaster
Commits
8506325c
Commit
8506325c
authored
Oct 26, 2018
by
Robert Goldmann
Browse files
Options
Downloads
Patches
Plain Diff
Fixed #334 - set log file path from code
parent
82a7c3da
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/main/java/de/deadlocker8/budgetmaster/Main.java
+4
-5
4 additions, 5 deletions
src/main/java/de/deadlocker8/budgetmaster/Main.java
src/main/resources/application.properties
+4
-0
4 additions, 0 deletions
src/main/resources/application.properties
with
8 additions
and
5 deletions
src/main/java/de/deadlocker8/budgetmaster/Main.java
+
4
−
5
View file @
8506325c
...
...
@@ -50,10 +50,6 @@ public class Main implements ApplicationRunner
Path
applicationSupportFolder
=
SystemUtils
.
getApplicationSupportDirectoryPath
(
Localization
.
getString
(
"folder"
));
PathUtils
.
createDirectoriesIfNotExists
(
applicationSupportFolder
);
Build
build
=
Build
.
getInstance
();
logAppInfo
(
build
.
getAppName
(),
build
.
getVersionName
(),
build
.
getVersionCode
(),
build
.
getVersionDate
());
ProgramArgs
.
setArgs
(
Arrays
.
asList
(
args
));
Path
settingsPath
=
applicationSupportFolder
.
resolve
(
"settings.properties"
);
...
...
@@ -71,12 +67,15 @@ public class Main implements ApplicationRunner
}
}
SpringApplication
.
run
(
Main
.
class
,
args
);
Path
logPath
=
applicationSupportFolder
.
resolve
(
"error.log"
);
SpringApplication
.
run
(
Main
.
class
,
"--logging.file="
+
logPath
.
toString
());
}
@Override
public
void
run
(
ApplicationArguments
args
)
{
Build
build
=
Build
.
getInstance
();
logAppInfo
(
build
.
getAppName
(),
build
.
getVersionName
(),
build
.
getVersionCode
(),
build
.
getVersionDate
());
}
private
static
void
logAppInfo
(
String
appName
,
String
versionName
,
String
versionCode
,
String
versionDate
)
{
...
...
This diff is collapsed.
Click to expand it.
src/main/resources/application.properties
+
4
−
0
View file @
8506325c
...
...
@@ -7,6 +7,10 @@ spring.jpa.properties.jadira.usertype.autoRegisterUserTypes = true
spring.http.multipart.max-file-size
=
100MB
spring.http.multipart.max-request-size
=
100MB
logging.level.root
=
INFO
#logging.level.org.springframework=ERROR
logging.level.de.deadlocker8
=
DEBUG
app.name
=
@project.artifactId@
app.version.code
=
@app.versionCode@
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment