From 3b389480f4ca819fb91794dcc581b99457a472b6 Mon Sep 17 00:00:00 2001 From: xxq250 Date: Fri, 24 May 2024 13:52:41 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9E=84=E5=BB=BA=E6=B5=81=E6=B0=B4=E7=BA=BFya?= =?UTF-8?q?ml,=20base64?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/controllers/api/v1/projects/pipelines_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/api/v1/projects/pipelines_controller.rb b/app/controllers/api/v1/projects/pipelines_controller.rb index 14b56350f..ddeb5f146 100644 --- a/app/controllers/api/v1/projects/pipelines_controller.rb +++ b/app/controllers/api/v1/projects/pipelines_controller.rb @@ -153,7 +153,7 @@ class Api::V1::Projects::PipelinesController < Api::V1::BaseController filepath: ".gitea/workflows/#{@pipeline.pipeline_name}.yml", branch: @pipeline.branch, new_branch: @pipeline.branch, - content: @pipeline.yaml, + content: Base64.encode64(@pipeline.yaml).gsub(/\n/, ''), message: "#{opt} pipeline", committer: { email: current_user.mail,