mirror of
https://github.com/github/codeql-action
synced 2026-05-23 20:00:54 +03:00
Add multi-language-repo
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
class Main {
|
||||
public static void main(String args[]) {
|
||||
if (true) {
|
||||
System.out.println("Hello, World!");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Executable
+8
@@ -0,0 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
gcc -o main main.c
|
||||
|
||||
dotnet build
|
||||
|
||||
javac Main.java
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Foo Show Ifs
|
||||
* @description Foo Show Ifs
|
||||
* @kind problem
|
||||
* @id complex-javascript-querypack/foo-show-ifs
|
||||
*/
|
||||
|
||||
import javascript
|
||||
|
||||
from IfStmt i
|
||||
select i, "foo if"
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Bar Show Ifs
|
||||
* @description Bar Show Ifs
|
||||
* @kind problem
|
||||
* @id complex-javascript-querypack/bar-ifs
|
||||
*/
|
||||
|
||||
import javascript
|
||||
|
||||
from IfStmt i
|
||||
select i, "bar if"
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Barfoobar Show Ifs
|
||||
* @description Barfoobar Show Ifs
|
||||
* @kind problem
|
||||
* @id complex-javascript-querypack/barfoobar-ifs
|
||||
*/
|
||||
|
||||
import javascript
|
||||
|
||||
from IfStmt i
|
||||
select i, "barfoobar if"
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Foo2 Show Ifs
|
||||
* @description Foo2 Show Ifs
|
||||
* @kind problem
|
||||
* @id complex-javascript-querypack/foo2-ifs
|
||||
*/
|
||||
|
||||
import javascript
|
||||
|
||||
from IfStmt i
|
||||
select i, "foo2 if"
|
||||
@@ -0,0 +1,3 @@
|
||||
name: complex-javascript-querypack
|
||||
version: 0.0.1
|
||||
libraryPathDependencies: codeql-javascript
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Root Show Ifs
|
||||
* @description Root Show Ifs
|
||||
* @kind problem
|
||||
* @id complex-javascript-querypack/root-show-ifs
|
||||
*/
|
||||
|
||||
import javascript
|
||||
|
||||
from IfStmt i
|
||||
select i, "root if"
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Foo/Bar Show Ifs
|
||||
* @description Foo/Bar Show Ifs
|
||||
* @kind problem
|
||||
* @id complex-python-querypack/foo/bar/show-ifs
|
||||
*/
|
||||
|
||||
import python
|
||||
|
||||
from If i
|
||||
select i, "foo/bar if"
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Foo Show Ifs
|
||||
* @description Foo Show Ifs
|
||||
* @kind problem
|
||||
* @id complex-python-querypack/foo/show-ifs
|
||||
*/
|
||||
|
||||
import python
|
||||
|
||||
from If i
|
||||
select i, "foo if"
|
||||
@@ -0,0 +1,3 @@
|
||||
name: inrepo-python-querypack
|
||||
version: 0.0.1
|
||||
libraryPathDependencies: codeql-python
|
||||
@@ -0,0 +1,2 @@
|
||||
- query: show_ifs.ql
|
||||
- query: foo/bar/show_ifs.ql
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Show Ifs
|
||||
* @description Show Ifs
|
||||
* @kind problem
|
||||
* @id complex-python-querypack/show-ifs
|
||||
*/
|
||||
|
||||
import python
|
||||
|
||||
from If i
|
||||
select i, "hello if"
|
||||
@@ -0,0 +1,3 @@
|
||||
name: inrepo-cpp-querypack
|
||||
version: 0.0.1
|
||||
libraryPathDependencies: codeql-cpp
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Show Cpp Ifs
|
||||
* @description Show Cpp Ifs
|
||||
* @kind problem
|
||||
* @id inrepo-cpp-querypack/show-ifs
|
||||
*/
|
||||
|
||||
import cpp
|
||||
|
||||
from IfStmt i
|
||||
select i, "hello if"
|
||||
@@ -0,0 +1,3 @@
|
||||
name: inrepo-csharp-querypack
|
||||
version: 0.0.1
|
||||
libraryPathDependencies: codeql-csharp
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Show Csharp Ifs
|
||||
* @description Show Csharp Ifs
|
||||
* @kind problem
|
||||
* @id inrepo-csharp-querypack/show-ifs
|
||||
*/
|
||||
|
||||
import csharp
|
||||
|
||||
from IfStmt i
|
||||
select i, "hello if"
|
||||
@@ -0,0 +1,3 @@
|
||||
name: inrepo-go-querypack
|
||||
version: 0.0.1
|
||||
libraryPathDependencies: codeql-go
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Show Go Ifs
|
||||
* @description Show Go Ifs
|
||||
* @kind problem
|
||||
* @id inrepo-go-querypack/show-ifs
|
||||
*/
|
||||
|
||||
import go
|
||||
|
||||
from IfStmt i
|
||||
select i, "hello if"
|
||||
@@ -0,0 +1,3 @@
|
||||
name: inrepo-java-querypack
|
||||
version: 0.0.1
|
||||
libraryPathDependencies: codeql-java
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Show Java Ifs
|
||||
* @description Show Java Ifs
|
||||
* @kind problem
|
||||
* @id inrepo-java-querypack/show-ifs
|
||||
*/
|
||||
|
||||
import java
|
||||
|
||||
from IfStmt i
|
||||
select i, "hello if"
|
||||
@@ -0,0 +1,3 @@
|
||||
name: inrepo-javascript-querypack
|
||||
version: 0.0.1
|
||||
libraryPathDependencies: codeql-javascript
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Show Javascript Ifs
|
||||
* @description Show Javascript Ifs
|
||||
* @kind problem
|
||||
* @id inrepo-javascript-querypack/show-ifs
|
||||
*/
|
||||
|
||||
import javascript
|
||||
|
||||
from IfStmt i
|
||||
select i, "hello if"
|
||||
@@ -0,0 +1,3 @@
|
||||
name: inrepo-python-querypack
|
||||
version: 0.0.1
|
||||
libraryPathDependencies: codeql-python
|
||||
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @name Show Python Ifs
|
||||
* @description Show Python Ifs
|
||||
* @kind problem
|
||||
* @id inrepo-python-querypack/show-ifs
|
||||
*/
|
||||
|
||||
import python
|
||||
|
||||
from If i
|
||||
select i, "hello if"
|
||||
@@ -0,0 +1,9 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||
<RootNamespace>multi_language_test</RootNamespace>
|
||||
</PropertyGroup>
|
||||
|
||||
</Project>
|
||||
@@ -0,0 +1,8 @@
|
||||
#include "stdio.h"
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
if (1) {
|
||||
printf("Hello, World!\n");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
using System;
|
||||
|
||||
namespace HelloWorldApp {
|
||||
class Geeks {
|
||||
static void Main(string[] args) {
|
||||
if (true) {
|
||||
Console.WriteLine("Hello World!");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
func main() {
|
||||
if true {
|
||||
fmt.Println("hello world")
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
if (true) {
|
||||
console.log("Hello, World!");
|
||||
}
|
||||
Executable
+9
@@ -0,0 +1,9 @@
|
||||
#!/usr/bin/python3
|
||||
|
||||
def main():
|
||||
if True:
|
||||
print("Hello, World!")
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
|
||||
Executable
+11
@@ -0,0 +1,11 @@
|
||||
#!/usr/bin/ruby
|
||||
# frozen_string_literal: true
|
||||
|
||||
def main
|
||||
v = ARGV[0]
|
||||
|
||||
puts 'with arg?' unless v.nil?
|
||||
puts 'hello there'
|
||||
end
|
||||
|
||||
main
|
||||
Reference in New Issue
Block a user