danger-packwerk 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,14 @@
1
+ # typed: strong
2
+
3
+ require 'danger-packwerk/private/deprecated_references'
4
+ require 'danger-packwerk/private/default_offenses_formatter'
5
+
6
+ module DangerPackwerk
7
+ #
8
+ # Anything within the Private module is subject to change.
9
+ #
10
+ module Private
11
+ end
12
+
13
+ private_constant :Private
14
+ end
@@ -0,0 +1,6 @@
1
+ # typed: strict
2
+ # frozen_string_literal: true
3
+
4
+ module DangerPackwerk
5
+ VERSION = '0.1.0'
6
+ end
@@ -0,0 +1,13 @@
1
+ # typed: strict
2
+
3
+ module DangerPackwerk
4
+ #
5
+ # This class represents the change in violations between a PR and its base.
6
+ #
7
+ class ViolationDiff < T::Struct
8
+ extend T::Sig
9
+
10
+ const :added_violations, T::Array[BasicReferenceOffense]
11
+ const :removed_violations, T::Array[BasicReferenceOffense]
12
+ end
13
+ end
@@ -0,0 +1,12 @@
1
+ # typed: strict # rubocop:disable Naming/FileName:
2
+ # frozen_string_literal: true
3
+
4
+ # This file exists so clients can call `require 'danger-packwerk'`
5
+ require 'sorbet-runtime'
6
+
7
+ module DangerPackwerk
8
+ DEPRECATED_REFERENCES_PATTERN = T.let(/.*?deprecated_references\.yml\z/.freeze, Regexp)
9
+
10
+ require 'danger-packwerk/danger_packwerk'
11
+ require 'danger-packwerk/danger_deprecated_references_yml_changes'
12
+ end
@@ -0,0 +1,4 @@
1
+ # typed: strict
2
+ # frozen_string_literal: true
3
+
4
+ require 'danger-packwerk'
data/sorbet/config ADDED
@@ -0,0 +1,3 @@
1
+ --dir
2
+ .
3
+ --enable-experimental-requires-ancestor
@@ -0,0 +1,122 @@
1
+ # typed: true
2
+
3
+ class Danger::DangerfileGitHubPlugin < ::Danger::Plugin
4
+ def initialize(dangerfile); end
5
+
6
+ def api; end
7
+ def base_commit; end
8
+ def branch_for_base; end
9
+ def branch_for_head; end
10
+ def dismiss_out_of_range_messages(dismiss = T.unsafe(nil)); end
11
+ def head_commit; end
12
+ def html_link(paths, full_path: T.unsafe(nil)); end
13
+ def mr_author; end
14
+ def mr_body; end
15
+ def mr_json; end
16
+ def mr_labels; end
17
+ def mr_title; end
18
+ def pr_author; end
19
+ def pr_body; end
20
+ def pr_diff; end
21
+ def pr_draft?; end
22
+ def pr_json; end
23
+ def pr_labels; end
24
+ def pr_title; end
25
+ def review; end
26
+
27
+ private
28
+
29
+ def create_link(href, text); end
30
+
31
+ class << self
32
+ def instance_name; end
33
+ def new(dangerfile); end
34
+ end
35
+ end
36
+
37
+ class Danger::CI
38
+ def initialize(_env); end
39
+
40
+ def pull_request_id; end
41
+ def pull_request_id=(_arg0); end
42
+ def repo_slug; end
43
+ def repo_slug=(_arg0); end
44
+ def repo_url; end
45
+ def repo_url=(_arg0); end
46
+ def supported_request_sources; end
47
+ def supported_request_sources=(_arg0); end
48
+ def supports?(request_source); end
49
+
50
+ class << self
51
+ def available_ci_sources; end
52
+ def inherited(child_class); end
53
+ def validates_as_ci?(_env); end
54
+ def validates_as_pr?(_env); end
55
+ end
56
+ end
57
+
58
+ class Danger::LocalGitRepo < ::Danger::CI
59
+ def initialize(env = T.unsafe(nil)); end
60
+
61
+ def base_commit; end
62
+ def base_commit=(_arg0); end
63
+ def git; end
64
+ def head_commit; end
65
+ def head_commit=(_arg0); end
66
+ def run_git(command); end
67
+ def supported_request_sources; end
68
+
69
+ private
70
+
71
+ def commits; end
72
+ def find_pull_request(env); end
73
+ def find_remote_info(env); end
74
+ def found_pull_request; end
75
+ def given_pull_request_url?(env); end
76
+ def missing_remote_error_message; end
77
+ def raise_error_for_missing_remote; end
78
+ def remote_info; end
79
+ def sha; end
80
+
81
+ class << self
82
+ def validates_as_ci?(env); end
83
+ def validates_as_pr?(_env); end
84
+ end
85
+ end
86
+
87
+
88
+ class Danger::DangerfileGitPlugin < ::Danger::Plugin
89
+ def initialize(dangerfile); end
90
+
91
+ def added_files; end
92
+ def commits; end
93
+ def deleted_files; end
94
+ def deletions; end
95
+ def diff; end
96
+ def diff_for_file(file); end
97
+ def info_for_file(file); end
98
+ def insertions; end
99
+ def lines_of_code; end
100
+ def modified_files; end
101
+ def renamed_files; end
102
+ def tags; end
103
+
104
+ class << self
105
+ def instance_name; end
106
+ end
107
+ end
108
+
109
+
110
+ class Danger::Plugin
111
+ sig { returns(Danger::DangerfileGitHubPlugin) }
112
+ def github; end
113
+
114
+ sig { returns(Danger::DangerfileGitPlugin) }
115
+ def git; end
116
+
117
+ def markdown(message, file:, line:); end
118
+ end
119
+
120
+ class Danger::Dangerfile; end
121
+ module Danger::EnvironmentManager; end
122
+ module DangerHelpers::Cork::Board; end