LoginSignup
0
0

More than 5 years have passed since last update.

STSでSpringBootプロジェクトを作ってバージョン管理を始めるまで

Posted at

SpringBoot/STS初学者なので忘れないようにメモです。

プロジェクトを作ろう

1.jpg

File > New > Spring Starter Project と選択しています。

2.jpeg

全部デフォルトのままでNextをクリック。

3.jpeg

以下を選択して、Finishをクリック。

  • MySQL
  • JDBC
  • MyBatis
  • Thymeleaf
  • Web

4.jpeg

はい、プロジェクトの作成完了です。

最近の流行りはapplication.yml

と、先輩から言われたので application.propertiesapplication.yml にrenameします。

5.jpeg

application.propertiesを右クリックして Refactor > Rename を選択

6.jpeg

拡張子を properties から yml に変更します。

7.jpeg

バージョン管理しときましょう。

8.jpeg

プロジェクトを右クリックして Team > Share Project... を選択

9.jpeg

10.jpeg

Use or create repository in pararent folder of project を選択してFinish。

これでgitでバージョン管理できるようになりました。

コミット

最初のコミットをしましょう。

11.jpeg

プロジェクトを右クリックして Team > Commit を選択。

12.jpeg

右上の方の+が重なったようなアイコンをクリック

13.jpeg

Unstaged Changesにあったファイルが全て Staged Changesに移ったら、コミット準備完了です。
Commit Messageに first commit と入力して右下のCommitをクリック。

これでプロジェクトができた段階でのバージョンがコミットできました。
さ、ゴリゴリ開発していきましょう。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0