Skip to content

Commit 4b18509

Browse files
committed
refactor: update java project
1 parent d039e4f commit 4b18509

File tree

65 files changed

+196
-6
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+196
-6
lines changed

Diff for: coding-test-java-practice/.gitignore

+186
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,186 @@
1+
### Java template
2+
# Compiled class file
3+
*.class
4+
5+
# Log file
6+
*.log
7+
8+
# BlueJ files
9+
*.ctxt
10+
11+
# Mobile Tools for Java (J2ME)
12+
.mtj.tmp/
13+
14+
# Package Files #
15+
*.jar
16+
*.war
17+
*.nar
18+
*.ear
19+
*.zip
20+
*.tar.gz
21+
*.rar
22+
23+
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
24+
hs_err_pid*
25+
replay_pid*
26+
27+
### Maven template
28+
target/
29+
pom.xml.tag
30+
pom.xml.releaseBackup
31+
pom.xml.versionsBackup
32+
pom.xml.next
33+
release.properties
34+
dependency-reduced-pom.xml
35+
buildNumber.properties
36+
.mvn/timing.properties
37+
# https://github.com/takari/maven-wrapper#usage-without-binary-jar
38+
.mvn/wrapper/maven-wrapper.jar
39+
40+
# Eclipse m2e generated files
41+
# Eclipse Core
42+
.project
43+
# JDT-specific (Eclipse Java Development Tools)
44+
.classpath
45+
46+
### VisualStudioCode template
47+
.vscode/*
48+
!.vscode/settings.json
49+
!.vscode/tasks.json
50+
!.vscode/launch.json
51+
!.vscode/extensions.json
52+
!.vscode/*.code-snippets
53+
54+
# Local History for Visual Studio Code
55+
.history/
56+
57+
# Built Visual Studio Code Extensions
58+
*.vsix
59+
60+
### JetBrains template
61+
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
62+
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
63+
64+
# User-specific stuff
65+
.idea/**/workspace.xml
66+
.idea/**/tasks.xml
67+
.idea/**/usage.statistics.xml
68+
.idea/**/dictionaries
69+
.idea/**/shelf
70+
71+
# AWS User-specific
72+
.idea/**/aws.xml
73+
74+
# Generated files
75+
.idea/**/contentModel.xml
76+
77+
# Sensitive or high-churn files
78+
.idea/**/dataSources/
79+
.idea/**/dataSources.ids
80+
.idea/**/dataSources.local.xml
81+
.idea/**/sqlDataSources.xml
82+
.idea/**/dynamic.xml
83+
.idea/**/uiDesigner.xml
84+
.idea/**/dbnavigator.xml
85+
86+
# Gradle
87+
.idea/**/gradle.xml
88+
.idea/**/libraries
89+
90+
# Gradle and Maven with auto-import
91+
# When using Gradle or Maven with auto-import, you should exclude module files,
92+
# since they will be recreated, and may cause churn. Uncomment if using
93+
# auto-import.
94+
# .idea/artifacts
95+
# .idea/compiler.xml
96+
# .idea/jarRepositories.xml
97+
# .idea/modules.xml
98+
# .idea/*.iml
99+
# .idea/modules
100+
# *.iml
101+
# *.ipr
102+
103+
# CMake
104+
cmake-build-*/
105+
106+
# Mongo Explorer plugin
107+
.idea/**/mongoSettings.xml
108+
109+
# File-based project format
110+
*.iws
111+
112+
# IntelliJ
113+
out/
114+
115+
# mpeltonen/sbt-idea plugin
116+
.idea_modules/
117+
118+
# JIRA plugin
119+
atlassian-ide-plugin.xml
120+
121+
# Cursive Clojure plugin
122+
.idea/replstate.xml
123+
124+
# SonarLint plugin
125+
.idea/sonarlint/
126+
127+
# Crashlytics plugin (for Android Studio and IntelliJ)
128+
com_crashlytics_export_strings.xml
129+
crashlytics.properties
130+
crashlytics-build.properties
131+
fabric.properties
132+
133+
# Editor-based Rest Client
134+
.idea/httpRequests
135+
136+
# Android studio 3.1+ serialized cache file
137+
.idea/caches/build_file_checksums.ser
138+
139+
### Gradle template
140+
.gradle
141+
**/build/
142+
!src/**/build/
143+
144+
# Ignore Gradle GUI config
145+
gradle-app.setting
146+
147+
# Avoid ignoring Gradle wrapper jar file (.jar files are usually ignored)
148+
!gradle-wrapper.jar
149+
150+
# Avoid ignore Gradle wrappper properties
151+
!gradle-wrapper.properties
152+
153+
# Cache of project
154+
.gradletasknamecache
155+
156+
# Eclipse Gradle plugin generated files
157+
# Eclipse Core
158+
.project
159+
# JDT-specific (Eclipse Java Development Tools)
160+
.classpath
161+
162+
### Kotlin template
163+
# Compiled class file
164+
*.class
165+
166+
# Log file
167+
*.log
168+
169+
# BlueJ files
170+
*.ctxt
171+
172+
# Mobile Tools for Java (J2ME)
173+
.mtj.tmp/
174+
175+
# Package Files #
176+
*.jar
177+
*.war
178+
*.nar
179+
*.ear
180+
*.zip
181+
*.tar.gz
182+
*.rar
183+
184+
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
185+
hs_err_pid*
186+
replay_pid*

Diff for: build.gradle renamed to coding-test-java-practice/build.gradle

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ plugins {
44

55
group = 'com.example'
66
version = '1.0-SNAPSHOT'
7+
description = 'Coding test practice for Programmers problems'
78

89
java {
910
sourceCompatibility = JavaVersion.VERSION_11
@@ -13,12 +14,12 @@ java {
1314
sourceSets {
1415
main {
1516
java {
16-
srcDirs = ['programmers']
17+
srcDirs = ['src/main/java']
1718
}
1819
}
1920
test {
2021
java {
21-
srcDirs = ['programmers/test']
22+
srcDirs = ['src/test/java']
2223
}
2324
}
2425
}
@@ -31,7 +32,6 @@ dependencies {
3132
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.0'
3233
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.9.0'
3334
testImplementation 'org.junit.jupiter:junit-jupiter-params:5.9.0'
34-
3535
}
3636

3737
test {
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2-bin.zip
44
networkTimeout=10000
5+
validateDistributionUrl=true
56
zipStoreBase=GRADLE_USER_HOME
67
zipStorePath=wrapper/dists

Diff for: gradlew renamed to coding-test-java-practice/gradlew

+4-1
Original file line numberDiff line numberDiff line change
@@ -130,10 +130,13 @@ location of your Java installation."
130130
fi
131131
else
132132
JAVACMD=java
133-
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
133+
if ! command -v java >/dev/null 2>&1
134+
then
135+
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
134136
135137
Please set the JAVA_HOME variable in your environment to match the
136138
location of your Java installation."
139+
fi
137140
fi
138141

139142
# Increase the maximum file descriptors if we can.
File renamed without changes.

Diff for: coding-test-java-practice/settings.gradle

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
rootProject.name = 'coding-test-java-practice'

Diff for: gradle/wrapper/gradle-wrapper.jar

-60.6 KB
Binary file not shown.

Diff for: settings.gradle

-1
This file was deleted.

0 commit comments

Comments
 (0)