Data Driven Model for Merge Tools
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 25/100
調査の方向性
まず ApprovalTests.cpp にある既存の merge-tool 実装と、それらが Linux、Mac、Windows でツールをどのように検索しているかを確認します。繰り返されているデータと複数バージョンに対する特別な処理を比較し、プラットフォーム固有の動作を失わずに、文書化されたケースを共通のデータ駆動設計でカバーできるかどうかを判断します。
索引モデルが issue の本文から書いたものです。
説明
This is just an idea to make adding new merge tools simpler. A lot of the merge tools function quite similarly and their implementations in ApprovalTests each require the creation of at least on class per merge tool. However, given multiple versions, names, or operating systems, the number of classes required increases. This amounts to quite a bit of boilerplate when adding new merge tools. By defining a struct for storing all of the necessary data, construction of one-off classes can be avoided, and this struct can provide all of the necessary details required to find and call a diff tool from within ApprovalTests.
An example struct as follows hopefully encapsulates most of the variance between merge tools.
#include <string>
#include <vector>
enum Context {
Background = 0;
Foreground
};
struct DiffTool {
std::string name;
std::vector<std::string> search_paths;
std::vector<std::string> names;
std::string arguments;
Context = Context::Background;
unsigned int priority = 0;
};
By defining a standard search procedure for the search_paths and names, each tool can be found using the same process. The search_paths and names members would likely need to be defined in a way to only include certain values dependent on the OS.
I'm not sure how viable this is, but I wanted to get the idea out there. It would be nice to only have to define most merge tools in one place.
Note: Multiple versions of the same tool would still require special handling.
- 主要言語
- C++
- スター
- 340
- フォーク
- 56
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
approvals/ApprovalTests.cpp のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
approvals/ApprovalTests.cpp#247 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
approvals/ApprovalTests.cpp#246 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
approvals/ApprovalTests.cpp#242 ·
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 45/100
approvals/ApprovalTests.cpp#226 · コメント 2 件 ·
-
bug namers
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
approvals/ApprovalTests.cpp#225 · コメント 5 件 ·
approvals/ApprovalTests.cpp の issue をすべて見る
似ている issue
-
難易度 2/5 半日 初心者へのやさしさ 84/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1〜3時間 初心者へのやさしさ 88/100
ROCm/rocm-libraries#12703 ·
メンテナーはふだん 2 日以内に返信
-
bug
難易度 1/5 1〜3時間 初心者へのやさしさ 88/100
isl-org/Open3D#7585 · コメント 1 件 ·
メンテナーはふだん 2 日以内に返信
-
Feature request
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
qbittorrent/qBittorrent#24975 ·
メンテナーはふだん 3 日以内に返信