diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-04-20 10:00:54 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-04-20 10:00:54 +0000 |
commit | 3cccd102ba543e02725d247893729e5c73b38295 (patch) | |
tree | f36a04ec38517f5deaaacb5acc7d949688d1e187 /lib/api/files.rb | |
parent | 205943281328046ef7b4528031b90fbda70c75ac (diff) | |
download | gitlab-ce-3cccd102ba543e02725d247893729e5c73b38295.tar.gz |
Add latest changes from gitlab-org/gitlab@14-10-stable-eev14.10.0-rc42
Diffstat (limited to 'lib/api/files.rb')
-rw-r--r-- | lib/api/files.rb | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/api/files.rb b/lib/api/files.rb index 39b3904ec90..41a8e899614 100644 --- a/lib/api/files.rb +++ b/lib/api/files.rb @@ -24,7 +24,8 @@ module API file_content_encoding: attrs[:encoding], author_email: attrs[:author_email], author_name: attrs[:author_name], - last_commit_sha: attrs[:last_commit_id] + last_commit_sha: attrs[:last_commit_id], + execute_filemode: attrs[:execute_filemode] } end @@ -65,7 +66,8 @@ module API ref: params[:ref], blob_id: @blob.id, commit_id: @commit.id, - last_commit_id: @repo.last_commit_id_for_path(@commit.sha, params[:file_path], literal_pathspec: true) + last_commit_id: @repo.last_commit_id_for_path(@commit.sha, params[:file_path], literal_pathspec: true), + execute_filemode: @blob.executable? } end @@ -83,6 +85,7 @@ module API requires :content, type: String, desc: 'File content' optional :encoding, type: String, values: %w[base64], desc: 'File encoding' optional :last_commit_id, type: String, desc: 'Last known commit id for this file' + optional :execute_filemode, type: Boolean, desc: 'Enable / Disable the executable flag on the file path' end end |