Skip to content

Commit 0ad462b

Browse files
committed
Allow custom codeowners path via environment variable
1 parent c56c55d commit 0ad462b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/code_ownership/private/codeowners_file.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,10 @@ def self.write!
111111

112112
sig { returns(Pathname) }
113113
def self.path
114-
Pathname.pwd.join('.github/CODEOWNERS')
114+
Pathname.pwd.join(
115+
ENV.fetch('CODEOWNERS_PATH', '.github'),
116+
'CODEOWNERS'
117+
)
115118
end
116119

117120
sig { params(files: T::Array[String]).void }

0 commit comments

Comments
 (0)