Browse Source

ADD sha for get trsitie-pileline.yml file api

tags/v1.0.0
Jasder 6 years ago
parent
commit
0b9a69ec56
2 changed files with 2 additions and 1 deletions
  1. +1
    -0
      README.md
  2. +1
    -1
      app/controllers/dev_ops/builds_controller.rb

+ 1
- 0
README.md View File

@@ -2429,6 +2429,7 @@ http://localhost:3000/api/dev_ops/builds/get_trustie_pipeline.json | jq
{
"name": ".trustie-pipeline.yml",
"path": ".trustie-pipeline.yml",
"sha": "548sfefsafef48sf485s4f",
"content": "..jsaf"
}
```


+ 1
- 1
app/controllers/dev_ops/builds_controller.rb View File

@@ -47,7 +47,7 @@ class DevOps::BuildsController < ApplicationController
file = interactor.result
return render json: {} if file[:status]

json = {name: file['name'], path: file['path'], content: render_decode64_content(file['content'])}
json = {name: file['name'], path: file['path'], sha: file['sha'], content: render_decode64_content(file['content'])}
render json: json
end
end


Loading…
Cancel
Save