Skip to content

Commit 0e5fe0f

Browse files
author
DABURON Vincent
committed
Version 1.1 change default Wiki Page Title Date format to be compatible with slug url
1 parent 533b0af commit 0e5fe0f

File tree

5 files changed

+10
-12
lines changed

5 files changed

+10
-12
lines changed

README.md

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,20 +33,19 @@ See the LICENSE file Apache 2 [https://www.apache.org/licenses/LICENSE-2.0](http
3333
## The wiki page generated
3434
Gitlab wiki page extract example 1 :
3535

36-
![wiki_page extract](doc/images/wiki_page_extract.png)
36+
![wiki_page extract 1](doc/images/wiki_page_extract.png)
3737

3838
Gitlab wiki page extract example 2 :
39-
![wiki_page extract](doc/images/wiki_page_extract2.png)
39+
![wiki_page extract 2](doc/images/wiki_page_extract2.png)
4040

4141

4242
## Usage Maven
43-
4443
The maven groupId, artifactId and version, this plugin is in the **Maven Central Repository**
4544

4645
```xml
4746
<groupId>io.github.vdaburon</groupId>
4847
<artifactId>create-gitlab-wiki-page-for-files-in-directory</artifactId>
49-
<version>1.0</version>
48+
<version>1.1</version>
5049
```
5150
Just include the plugin in your `pom.xml` and execute `mvn verify` <br>
5251
or with parameters overwriting properties `mvn -DgitlabUrl=https://mygitlab.com -DprojectId=12344 -DaccessToken=SLKJtokenLMJI -DpageTitle="Load test 05_03_2023" verify`<br>
@@ -68,7 +67,7 @@ or individual launch `mvn -DaccessToken=mytokenLMJI exec:java@create_gitlab_wiki
6867
<dependency>
6968
<groupId>io.github.vdaburon</groupId>
7069
<artifactId>create-gitlab-wiki-page-for-files-in-directory</artifactId>
71-
<version>1.0</version>
70+
<version>1.1</version>
7271
</dependency>
7372
</dependencies>
7473

@@ -116,13 +115,12 @@ java -jar create-gitlab-wiki-page-for-files-in-directory-&lt;version&gt;.jar -gi
116115
</pre>
117116

118117
## Link to others projects
119-
Usally this plugin is use with [jmeter-graph-tool-maven-plugin](https://github.com/vdaburon/jmeter-graph-tool-maven-plugin)
120-
118+
Usally this plugin is use with [jmeter-graph-tool-maven-plugin](https://github.com/vdaburon/jmeter-graph-tool-maven-plugin)<br>
121119
and this plugin [csv-report-to-html](https://github.com/vdaburon/JMReportCsvToHtml)
122-
123120
1) The **jmeter-graph-tool-maven-plugin** create the report csv files and graphs
124121
2) The **csv-report-to-html** create the **html table report** from the csv file
125122

126123
## Versions
124+
Version 1.1 change default Wiki Page Title and the Date Format to be more compatible with slug link (remove ':')<br>
127125
Version 1.0 initial version test with Gitlab version 15.10
128126

doc/images/wiki_page_extract.png

34.1 KB
Loading

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
<groupId>io.github.vdaburon</groupId>
88
<artifactId>create-gitlab-wiki-page-for-files-in-directory</artifactId>
9-
<version>1.0</version>
9+
<version>1.1</version>
1010
<packaging>jar</packaging>
1111
<name>Create Gitlab Wiki Page for files in directory</name>
1212
<description>A tool that creates a new Gitlab Wiki Page for files in the directory to display graphics and link files</description>

shell/lance_genere_wiki_page_no_param.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ set ACCESS_TOKEN=WetokenE7
55
set DIR_WITH_FILE=C:/result
66
set IMAGE_WIDTH=950
77
rem set PAGE_TITLE="load test 05_03_2023 13h25m12s"
8-
%JAVA_HOME%\bin\java.exe -jar ../target/create-gitlab-wiki-page-for-files-in-directory-1.0-jar-with-dependencies.jar -gitlabUrl %GITLAB_URL% -projectId %PROJECT_ID% -accessToken %ACCESS_TOKEN% -dirWithFile %DIR_WITH_FILE% -imageWidth %IMAGE_WIDTH%
8+
%JAVA_HOME%\bin\java.exe -jar ../target/create-gitlab-wiki-page-for-files-in-directory-1.1-jar-with-dependencies.jar -gitlabUrl %GITLAB_URL% -projectId %PROJECT_ID% -accessToken %ACCESS_TOKEN% -dirWithFile %DIR_WITH_FILE% -imageWidth %IMAGE_WIDTH%

src/main/java/io/github/vdaburon/jmeter/utils/WikiPageGenerator.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,13 +157,13 @@ public static String createWikiPage(GitlabWikiApi gitlabWikiApi, String pageTitl
157157
try {
158158
LOGGER.info("Generating gitlab wiki page ...");
159159

160-
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss", Locale.getDefault());
160+
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH'h'mm'm'ss's'", Locale.getDefault());
161161
String sDate = dateFormat.format(new Date());
162162

163163
sb.append("<h1> Generated date " + sDate + "</h1><br/>");
164164
sb.append(LINE_SEP);
165165

166-
String pageTitleWikiPage = "Page wiki generated " + sDate;
166+
String pageTitleWikiPage = sDate + " Page Wiki Generated";
167167
if (pageTitle != null && pageTitle.length() > 1) {
168168
pageTitleWikiPage = pageTitle;
169169
}

0 commit comments

Comments
 (0)