Skip to content

Commit

Permalink
to accommodate both SSH and HTTP
Browse files Browse the repository at this point in the history
  • Loading branch information
meltingrabbit committed Dec 15, 2023
1 parent 11b08aa commit 365db7f
Show file tree
Hide file tree
Showing 16 changed files with 18 additions and 17 deletions.
5 changes: 3 additions & 2 deletions code-generator/my_mod/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ def GenerateSettingNote(settings):
note += GetRepoName_(settings["path_to_db"])
note += "\n"
note += " * db commit hash: "
note += "xxxx"
# note += GetCommitHash_(settings["path_to_db"])
note += "\n"
note += " * @note コード生成パラメータ:\n"
Expand Down Expand Up @@ -103,8 +104,8 @@ def GetRepoName_(path):
result = subprocess.run(["git", "remote", "-v"], cwd=path, text=True, capture_output=True, check=True)
url = result.stdout.split('\n')[0].split('\t')[1].split(' ')[0] # 最初のリモートURLを取得

# URLからユーザー名とリポジトリ名を抽出
match = re.search(r'github.com[:/](.+)/(.+)\.git', url)
# URLからユーザー名とリポジトリ名を抽出(HTTPSとSSHの両方に対応)
match = re.search(r'(?:github\.com[:/])(.+)/(.+)\.git', url)
if match:
return f"{match.group(1)}/{match.group(2)}"
else:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash: f7b24980106fed976f894ffd96608dfa24ad271d
* db commit hash: 11b08aacb01a9a39c6807928b35628e2c946369d
* @note コード生成パラメータ:
* name: AOBC
* db_prefix: SAMPLE_AOBC
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash: f7b24980106fed976f894ffd96608dfa24ad271d
* db commit hash: 11b08aacb01a9a39c6807928b35628e2c946369d
* @note コード生成パラメータ:
* name: AOBC
* db_prefix: SAMPLE_AOBC
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash: f7b24980106fed976f894ffd96608dfa24ad271d
* db commit hash: 11b08aacb01a9a39c6807928b35628e2c946369d
* @note コード生成パラメータ:
* name: AOBC
* db_prefix: SAMPLE_AOBC
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash: f7b24980106fed976f894ffd96608dfa24ad271d
* db commit hash: 11b08aacb01a9a39c6807928b35628e2c946369d
* @note コード生成パラメータ:
* name: AOBC
* db_prefix: SAMPLE_AOBC
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash: f7b24980106fed976f894ffd96608dfa24ad271d
* db commit hash: 11b08aacb01a9a39c6807928b35628e2c946369d
* @note コード生成パラメータ:
* name: AOBC
* db_prefix: SAMPLE_AOBC
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_MOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
2 changes: 1 addition & 1 deletion examples/mobc/src/src_user/tlm_cmd/command_definitions.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_MOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
2 changes: 1 addition & 1 deletion examples/mobc/src/src_user/tlm_cmd/command_definitions.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_MOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
2 changes: 1 addition & 1 deletion examples/mobc/src/src_user/tlm_cmd/telemetry_definitions.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_MOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
2 changes: 1 addition & 1 deletion examples/mobc/src/src_user/tlm_cmd/telemetry_definitions.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_MOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_AOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
2 changes: 1 addition & 1 deletion examples/subobc/src/src_user/tlm_cmd/command_definitions.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_AOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
2 changes: 1 addition & 1 deletion examples/subobc/src/src_user/tlm_cmd/command_definitions.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_AOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_AOBC
* tlm_id_range: [0x00, 0x100]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* @note このコードは自動生成されています!
* @note コード生成 tlm-cmd-db:
* repository: arkedge/c2a-core
* db commit hash:
* db commit hash: xxxx
* @note コード生成パラメータ:
* db_prefix: SAMPLE_AOBC
* tlm_id_range: [0x00, 0x100]
Expand Down

0 comments on commit 365db7f

Please sign in to comment.