File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -729,11 +729,16 @@ lane :validate_public_interface do
729
729
sh ( "wget -P . https://github.com/GetStream/stream-module-interface-analyser/releases/download/v1.0.7/interface-analyser" )
730
730
sh ( "chmod +x #{ analyser } " )
731
731
732
+ # Run the analysis on the current branch
733
+ original_branch = current_branch
732
734
sh ( "./#{ analyser } analysis ../Sources/ ../public_interface_current.json" )
733
735
734
- target_branch = current_branch . include? ( 'release/' ) ? 'main' : 'develop'
736
+ # Checkout the target branch
737
+ target_branch = original_branch . include? ( 'release/' ) ? 'main' : 'develop'
735
738
sh ( "git fetch origin #{ target_branch } " )
736
739
sh ( "git checkout #{ target_branch } " )
740
+
741
+ # Run the analysis on the target branch
737
742
sh ( "./#{ analyser } analysis ../Sources/ ../public_interface_previous.json" )
738
743
739
744
# Run diff
@@ -754,6 +759,9 @@ lane :validate_public_interface do
754
759
755
760
# Post PR comment if running in CI
756
761
pr_comment ( text : content , edit_last_comment_with_text : header ) if is_ci
762
+
763
+ # Checkout the original branch
764
+ sh ( "git checkout #{ original_branch } " )
757
765
end
758
766
759
767
lane :show_frameworks_sizes do |options |
You can’t perform that action at this time.
0 commit comments