You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# CodeQL supports the following values keywords for 'language': 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'swift'
61
-
# Use `c-cpp` to analyze code written in C, C++ or both
62
-
# Use 'java-kotlin' to analyze code written in Java, Kotlin or both
63
-
# Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both
46
+
language: [swift]
47
+
build-mode: [manual]
64
48
# To learn more about changing the languages that are analyzed or customizing the build mode for your analysis,
65
49
# see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning.
66
50
# If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how
67
51
# your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
52
+
68
53
steps:
54
+
# This step initializes the in the matrix specified version of Xcode.
69
55
- name: Initialize latest xcode
70
56
uses: maxim-lobanov/setup-xcode@v1.6.0
71
57
with:
72
58
xcode-version: ${{ matrix.xcode }}
73
59
60
+
# This step removes all other versions of Xcode from the machine.
# Initialize Swift in the matrix specified version.
83
71
- name: Initialize Swift
84
72
uses: swift-actions/setup-swift@v2.1.0
85
73
with:
86
74
swift-version: ${{ matrix.swift }}
87
75
76
+
# Get the Swift version.
88
77
- name: Get swift version
89
78
run: swift --version
90
79
80
+
# Checkout the repository.
91
81
- name: Checkout repository
92
82
uses: actions/checkout@v4.1.7
93
83
84
+
# Initialize CodeQL.
94
85
- name: Initialize CodeQL
95
86
uses: github/codeql-action/init@v3.26.6
96
87
with:
97
88
languages: ${{ matrix.language }}
98
89
build-mode: ${{ matrix.build-mode }}
99
-
# If you wish to specify custom queries, you can do so here or in a config file.
100
-
# By default, queries listed here will override any specified in a config file.
101
-
# Prefix the list here with "+" to use these queries and those in the config file.
102
90
103
91
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
104
92
# queries: security-extended,security-and-quality
105
93
queries: security-and-quality
106
94
107
-
# If the analyze step fails for one of the languages you are analyzing with
108
-
# "We were unable to automatically build your code", modify the matrix above
109
-
# to set the build mode to "manual" for that language. Then modify this step
110
-
# to build your code.
111
95
# ℹ️ Command-line programs to run using the OS shell.
112
96
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
113
97
@@ -117,31 +101,19 @@ jobs:
117
101
#- name: Autobuild
118
102
# uses: github/codeql-action/autobuild@v3.26.5
119
103
104
+
# Check disk space.
120
105
- name: Check Disk Space
121
106
run: |
122
107
sleep 10
123
108
df -h
124
109
110
+
# Manual build with the release configuration.
125
111
- name: Manual build
126
-
run: swift build
127
-
128
-
#- if: matrix.build-mode == 'manual'
129
-
# shell: bash
130
-
# run: |
131
-
# echo 'If you are using a "manual" build mode for one or more of the' \
132
-
# 'languages you are analyzing, replace this with the commands to build' \
133
-
# 'your code, for example:'
134
-
# echo ' make bootstrap'
135
-
# echo ' make release'
136
-
#
137
-
# swift build
138
-
#
139
-
# echo ' swift build -c release '
140
-
#
141
-
# exit 1
142
-
112
+
run: swift build --build-tests --configuration debug -v
143
113
114
+
# Perform CodeQL analysis after the build has completed successfully or failed.
- "platform=iOS Simulator,OS=18.1,name=iPhone 15 Pro Max"
62
-
include:
63
-
- language: swift
64
-
build-mode: manual
65
-
# CodeQL supports the following values keywords for 'language': 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'swift'
66
-
# Use `c-cpp` to analyze code written in C, C++ or both
67
-
# Use 'java-kotlin' to analyze code written in Java, Kotlin or both
68
-
# Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both
69
51
# To learn more about changing the languages that are analyzed or customizing the build mode for your analysis,
70
52
# see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning.
71
53
# If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how
72
54
# your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
# Initialize Swift in the matrix specified version.
88
74
- name: Initialize Swift
89
75
uses: swift-actions/setup-swift@v2.1.0
90
76
with:
91
77
swift-version: ${{ matrix.swift }}
92
78
79
+
# Get the Swift version.
93
80
- name: Get swift version
94
81
run: swift --version
95
82
83
+
# Checkout the repository.
96
84
- name: Checkout repository
97
85
uses: actions/checkout@v4.1.7
98
86
87
+
# Initialize CodeQL.
99
88
- name: Initialize CodeQL
100
89
uses: github/codeql-action/init@v3.26.6
101
90
with:
102
91
languages: ${{ matrix.language }}
103
92
build-mode: ${{ matrix.build-mode }}
104
-
# If you wish to specify custom queries, you can do so here or in a config file.
105
-
# By default, queries listed here will override any specified in a config file.
106
-
# Prefix the list here with "+" to use these queries and those in the config file.
107
93
108
94
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
0 commit comments