Skip to content

Commit da98925

Browse files
committed
Bun and Swift engine definitions
1 parent fb771c1 commit da98925

File tree

3 files changed

+35
-1
lines changed

3 files changed

+35
-1
lines changed

src/engines/bun.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@ export const bun: RegexEngine = {
1616
},
1717
logo_icon: "https://www.vectorlogo.zone/logos/bunsh/bunsh-icon.svg",
1818
logo_ar21: "https://www.vectorlogo.zone/logos/bunsh/bunsh-ar21.svg",
19-
nodeping_url: "https://nodeping.com/reports/checks/LATER",
19+
nodeping_url:
20+
"https://nodeping.com/reports/checks/iajucfo0-kq0e-47ql-82sk-xoji0l2ejmfw",
2021
notfound: ["javascript", "typescript"],
2122
options: [
2223
{

src/engines/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import { postgresql } from "./postgresql";
1515
import { python } from "./python";
1616
import { ruby } from "./ruby";
1717
import { rust } from "./rust";
18+
import { swift } from "./swift";
1819
import { tcl } from "./tcl";
1920
import { xregexp } from "./xregexp";
2021
import { TestInput } from "@/types/TestInput";
@@ -34,6 +35,7 @@ const engineMap = new Map<string, RegexEngine>([
3435
[python.handle, python],
3536
[ruby.handle, ruby],
3637
[rust.handle, rust],
38+
[swift.handle, swift],
3739
[tcl.handle, tcl],
3840
[xregexp.handle, xregexp],
3941
]);

src/engines/swift.ts

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import type { RegexEngine } from "./RegexEngine";
2+
3+
export const swift: RegexEngine = {
4+
description: "",
5+
enabled: true,
6+
help_label: "Regex Structure",
7+
help_url: "https://developer.apple.com/documentation/swift/regex",
8+
handle: "swift",
9+
level: "alpha",
10+
links: {
11+
RegexBuilder: "https://developer.apple.com/documentation/regexbuilder",
12+
},
13+
logo_icon: "https://www.vectorlogo.zone/logos/swift/swift-icon.svg",
14+
logo_ar21: "https://www.vectorlogo.zone/logos/swift/swift-ar21.svg",
15+
nodeping_url:
16+
"https://nodeping.com/reports/checks/sd8rr8e8-0vw2-4cur-87tg-tnm9et6pc6w5",
17+
options: [
18+
{ code: "anchorsMatchLineEndings", description: "the start and end of input anchors (^ and $) also match against the start and end of a line." },
19+
{ code: "asciiOnlyCharacterClasses", description: "only ASCII characters when matching character classes." },
20+
{ code: "asciiOnlyDigits", description: "only ASCII characters as digits" },
21+
{ code: "asciiOnlyWhitespace", description: "only ASCII characters as space characters" },
22+
{ code: "asciiOnlyWordCharacters", description: "only ASCII characters as word characters" },
23+
{ code: "dotMatchesNewlines", description: "the “any” metacharacter (.) also matches against the start and end of a line." },
24+
{ code: "ignoresCase", description: "ignores case when matching" },
25+
{ code: "unicodeMatchingSemantics", description: "use Unicode scalar matching sematics" },
26+
],
27+
short_name: "Swift",
28+
source_url: "https://github.com/regexplanet/regexplanet-swift",
29+
status_url: "https://swift.gcr.regexplanet.com/status.json",
30+
test_url: "https://swift.gcr.regexplanet.com/test.json",
31+
};

0 commit comments

Comments
 (0)