mirror of
https://github.com/alecthomas/chroma.git
synced 2025-02-05 13:05:18 +02:00
34 Commits
Author | SHA1 | Message | Date | |
---|---|---|---|---|
renovate[bot]
|
6622bd571f
|
chore(deps): update all non-major dependencies (#1013)
This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | Type | Update | |---|---|---|---|---|---|---|---| | [github.com/alecthomas/kong](https://redirect.github.com/alecthomas/kong) | `v1.2.1` -> `v1.4.0` | [![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2falecthomas%2fkong/v1.4.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/go/github.com%2falecthomas%2fkong/v1.4.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/go/github.com%2falecthomas%2fkong/v1.2.1/v1.4.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2falecthomas%2fkong/v1.2.1/v1.4.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | require | minor | | [go](https://redirect.github.com/golang/go) | `1.23.2` -> `1.23.3` | [![age](https://developer.mend.io/api/mc/badges/age/hermit/go/1.23.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/hermit/go/1.23.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/hermit/go/1.23.2/1.23.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/hermit/go/1.23.2/1.23.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | patch | | [hyperfine](https://redirect.github.com/sharkdp/hyperfine) | `1.18.0` -> `1.19.0` | [![age](https://developer.mend.io/api/mc/badges/age/hermit/hyperfine/1.19.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/hermit/hyperfine/1.19.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/hermit/hyperfine/1.18.0/1.19.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/hermit/hyperfine/1.18.0/1.19.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | minor | | [watchexec](https://redirect.github.com/watchexec/watchexec) | `2.1.2` -> `2.2.0` | [![age](https://developer.mend.io/api/mc/badges/age/hermit/watchexec/2.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/hermit/watchexec/2.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/hermit/watchexec/2.1.2/2.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/hermit/watchexec/2.1.2/2.2.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | minor | --- ### Release Notes <details> <summary>alecthomas/kong (github.com/alecthomas/kong)</summary> ### [`v1.4.0`](https://redirect.github.com/alecthomas/kong/compare/v1.3.0...v1.4.0) [Compare Source](https://redirect.github.com/alecthomas/kong/compare/v1.3.0...v1.4.0) ### [`v1.3.0`](https://redirect.github.com/alecthomas/kong/compare/v1.2.1...v1.3.0) [Compare Source](https://redirect.github.com/alecthomas/kong/compare/v1.2.1...v1.3.0) </details> <details> <summary>golang/go (go)</summary> ### [`v1.23.3`](https://redirect.github.com/golang/go/compare/go1.23.2...go1.23.3) </details> <details> <summary>sharkdp/hyperfine (hyperfine)</summary> ### [`v1.19.0`](https://redirect.github.com/sharkdp/hyperfine/blob/HEAD/CHANGELOG.md#v1190) #### Features - Add a new `--reference <cmd>` option to specify a reference command for the relative speed comparison, see [#​579](https://redirect.github.com/sharkdp/hyperfine/issues/579), [#​577](https://redirect.github.com/sharkdp/hyperfine/issues/577) and [#​744](https://redirect.github.com/sharkdp/hyperfine/issues/744) ([@​sharkdp](https://redirect.github.com/sharkdp)) - Add `--conclude` argument (analog to `--prepare`), see [#​565](https://redirect.github.com/sharkdp/hyperfine/issues/565) and [#​719](https://redirect.github.com/sharkdp/hyperfine/issues/719) ([@​jackoconnordev](https://redirect.github.com/jackoconnordev)) - Allow `--output=…` to appear once for each command, enabling use cases like `hyperfine --output=null my-cmd --output=./file.log my-cmd`, see [#​529](https://redirect.github.com/sharkdp/hyperfine/issues/529) and [#​775](https://redirect.github.com/sharkdp/hyperfine/issues/775) ([@​sharkdp](https://redirect.github.com/sharkdp)) - The environment variable `$HYPERFINE_ITERATION` will now contain the current iteration number for each benchmarked command, see [#​775](https://redirect.github.com/sharkdp/hyperfine/issues/775) ([@​sharkdp](https://redirect.github.com/sharkdp)) - Add iteration information to failure error message, see [#​771](https://redirect.github.com/sharkdp/hyperfine/issues/771) and [#​772](https://redirect.github.com/sharkdp/hyperfine/issues/772) ([@​sharkdp](https://redirect.github.com/sharkdp)) - Python scripts: - legend modification parameters and output DPI, see [#​758](https://redirect.github.com/sharkdp/hyperfine/issues/758) ([@​Spreadcat](https://redirect.github.com/Spreadcat)) - Nicer whiskers plot, see [#​727](https://redirect.github.com/sharkdp/hyperfine/issues/727) ([@​serpent7776](https://redirect.github.com/serpent7776)) #### Bugfixes - ETA not clearly visible on terminals with a block cursor, see [#​698](https://redirect.github.com/sharkdp/hyperfine/issues/698) and [#​699](https://redirect.github.com/sharkdp/hyperfine/issues/699) ([@​overclockworked64](https://redirect.github.com/overclockworked64)) - Fix zsh completions, see [#​717](https://redirect.github.com/sharkdp/hyperfine/issues/717) ([@​xzfc](https://redirect.github.com/xzfc)) #### Other - Build binaries for aarch64-apple-darwin, see [#​728](https://redirect.github.com/sharkdp/hyperfine/issues/728) ([@​Phault](https://redirect.github.com/Phault)) - Various cleanups ([@​hamirmahal](https://redirect.github.com/hamirmahal), [@​one230six](https://redirect.github.com/one230six)) </details> <details> <summary>watchexec/watchexec (watchexec)</summary> ### [`v2.2.0`](https://redirect.github.com/watchexec/watchexec/releases/tag/v2.2.0): CLI v2.2.0 - Explicitly watching files that are in your .gitignore no longer requires `--no-vcs-ignore` ([#​674](https://redirect.github.com/watchexec/watchexec/issues/674), [#​859](https://redirect.github.com/watchexec/watchexec/issues/859), contributed by [@​TheBlek](https://redirect.github.com/TheBlek)) - Fix Windows usage for legacy programs due to usage of UNC paths ([#​830](https://redirect.github.com/watchexec/watchexec/issues/830), [#​858](https://redirect.github.com/watchexec/watchexec/issues/858), contributed by [@​TheBlek](https://redirect.github.com/TheBlek)) - Various dependency upgrades </details> --- ### Configuration 📅 **Schedule**: Branch creation - "before 4am on Monday" (UTC), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://redirect.github.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/alecthomas/chroma). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOC4xMjAuMSIsInVwZGF0ZWRJblZlciI6IjM5LjkuNSIsInRhcmdldEJyYW5jaCI6Im1hc3RlciIsImxhYmVscyI6W119--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> |
||
renovate[bot]
|
7a4d1d9cbf
|
chore(deps): update module github.com/alecthomas/kong to v1 (#999)
This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [github.com/alecthomas/kong](https://redirect.github.com/alecthomas/kong) | `v0.9.0` -> `v1.2.1` | [![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2falecthomas%2fkong/v1.2.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/go/github.com%2falecthomas%2fkong/v1.2.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/go/github.com%2falecthomas%2fkong/v0.9.0/v1.2.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2falecthomas%2fkong/v0.9.0/v1.2.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>alecthomas/kong (github.com/alecthomas/kong)</summary> ### [`v1.2.1`](https://redirect.github.com/alecthomas/kong/compare/v1.2.0...v1.2.1) [Compare Source](https://redirect.github.com/alecthomas/kong/compare/v1.2.0...v1.2.1) ### [`v1.2.0`](https://redirect.github.com/alecthomas/kong/compare/v1.1.0...v1.2.0) [Compare Source](https://redirect.github.com/alecthomas/kong/compare/v1.1.0...v1.2.0) ### [`v1.1.0`](https://redirect.github.com/alecthomas/kong/compare/v1.0.0...v1.1.0) [Compare Source](https://redirect.github.com/alecthomas/kong/compare/v1.0.0...v1.1.0) ### [`v1.0.0`](https://redirect.github.com/alecthomas/kong/compare/v0.9.0...v1.0.0) [Compare Source](https://redirect.github.com/alecthomas/kong/compare/v0.9.0...v1.0.0) </details> --- ### Configuration 📅 **Schedule**: Branch creation - "before 4am on Monday" (UTC), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/alecthomas/chroma). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOC43NC4xIiwidXBkYXRlZEluVmVyIjoiMzguNzQuMSIsInRhcmdldEJyYW5jaCI6Im1hc3RlciIsImxhYmVscyI6W119--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> |
||
renovate[bot]
|
b35d6a86c7
|
chore(deps): update all non-major dependencies (#955)
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Type | Update | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---|---|---| | [esbuild](https://togithub.com/evanw/esbuild) | | minor | `0.20.2` -> `0.21.4` | [![age](https://developer.mend.io/api/mc/badges/age/hermit/esbuild/0.21.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/hermit/esbuild/0.21.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/hermit/esbuild/0.20.2/0.21.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/hermit/esbuild/0.20.2/0.21.4?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [github.com/alecthomas/assert/v2](https://togithub.com/alecthomas/assert) | require | minor | `v2.7.0` -> `v2.10.0` | [![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2falecthomas%2fassert%2fv2/v2.10.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/go/github.com%2falecthomas%2fassert%2fv2/v2.10.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/go/github.com%2falecthomas%2fassert%2fv2/v2.7.0/v2.10.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2falecthomas%2fassert%2fv2/v2.7.0/v2.10.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [github.com/alecthomas/chroma/v2](https://togithub.com/alecthomas/chroma) | require | minor | `v2.13.0` -> `v2.14.0` | [![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2falecthomas%2fchroma%2fv2/v2.14.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/go/github.com%2falecthomas%2fchroma%2fv2/v2.14.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/go/github.com%2falecthomas%2fchroma%2fv2/v2.13.0/v2.14.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2falecthomas%2fchroma%2fv2/v2.13.0/v2.14.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [go](https://togithub.com/golang/go) | | patch | `1.22.1` -> `1.22.3` | [![age](https://developer.mend.io/api/mc/badges/age/hermit/go/1.22.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/hermit/go/1.22.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/hermit/go/1.22.1/1.22.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/hermit/go/1.22.1/1.22.3?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [goreleaser](https://togithub.com/goreleaser/goreleaser) | | minor | `1.24.0` -> `1.26.2` | [![age](https://developer.mend.io/api/mc/badges/age/hermit/goreleaser/1.26.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/hermit/goreleaser/1.26.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/hermit/goreleaser/1.24.0/1.26.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/hermit/goreleaser/1.24.0/1.26.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>evanw/esbuild (esbuild)</summary> ### [`v0.21.4`](https://togithub.com/evanw/esbuild/blob/HEAD/CHANGELOG.md#0214) [Compare Source](https://togithub.com/evanw/esbuild/compare/v0.21.3...v0.21.4) - Update support for import assertions and import attributes in node ([#​3778](https://togithub.com/evanw/esbuild/issues/3778)) Import assertions (the `assert` keyword) have been removed from node starting in v22.0.0. So esbuild will now strip them and generate a warning with `--target=node22` or above: ▲ [WARNING] The "assert" keyword is not supported in the configured target environment ("node22") [assert-to-with] example.mjs:1:40: 1 │ import json from "esbuild/package.json" assert { type: "json" } │ ~~~~~~ ╵ with Did you mean to use "with" instead of "assert"? Import attributes (the `with` keyword) have been backported to node 18 starting in v18.20.0. So esbuild will no longer strip them with `--target=node18.N` if `N` is 20 or greater. - Fix `for await` transform when a label is present This release fixes a bug where the `for await` transform, which wraps the loop in a `try` statement, previously failed to also move the loop's label into the `try` statement. This bug only affects code that uses both of these features in combination. Here's an example of some affected code: ```js // Original code async function test() { outer: for await (const x of [Promise.resolve([0, 1])]) { for (const y of x) if (y) break outer throw 'fail' } } // Old output (with --target=es6) function test() { return __async(this, null, function* () { outer: try { for (var iter = __forAwait([Promise.resolve([0, 1])]), more, temp, error; more = !(temp = yield iter.next()).done; more = false) { const x = temp.value; for (const y of x) if (y) break outer; throw "fail"; } } catch (temp) { error = [temp]; } finally { try { more && (temp = iter.return) && (yield temp.call(iter)); } finally { if (error) throw error[0]; } } }); } // New output (with --target=es6) function test() { return __async(this, null, function* () { try { outer: for (var iter = __forAwait([Promise.resolve([0, 1])]), more, temp, error; more = !(temp = yield iter.next()).done; more = false) { const x = temp.value; for (const y of x) if (y) break outer; throw "fail"; } } catch (temp) { error = [temp]; } finally { try { more && (temp = iter.return) && (yield temp.call(iter)); } finally { if (error) throw error[0]; } } }); } ``` - Do additional constant folding after cross-module enum inlining ([#​3416](https://togithub.com/evanw/esbuild/issues/3416), [#​3425](https://togithub.com/evanw/esbuild/issues/3425)) This release adds a few more cases where esbuild does constant folding after cross-module enum inlining. ```ts // Original code: enum.ts export enum Platform { WINDOWS = 'windows', MACOS = 'macos', LINUX = 'linux', } // Original code: main.ts import { Platform } from './enum'; declare const PLATFORM: string; export function logPlatform() { if (PLATFORM == Platform.WINDOWS) console.log('Windows'); else if (PLATFORM == Platform.MACOS) console.log('macOS'); else if (PLATFORM == Platform.LINUX) console.log('Linux'); else console.log('Other'); } // Old output (with --bundle '--define:PLATFORM="macos"' --minify --format=esm) function n(){"windows"=="macos"?console.log("Windows"):"macos"=="macos"?console.log("macOS"):"linux"=="macos"?console.log("Linux"):console.log("Other")}export{n as logPlatform}; // New output (with --bundle '--define:PLATFORM="macos"' --minify --format=esm) function n(){console.log("macOS")}export{n as logPlatform}; ``` - Pass import attributes to on-resolve plugins ([#​3384](https://togithub.com/evanw/esbuild/issues/3384), [#​3639](https://togithub.com/evanw/esbuild/issues/3639), [#​3646](https://togithub.com/evanw/esbuild/issues/3646)) With this release, on-resolve plugins will now have access to the import attributes on the import via the `with` property of the arguments object. This mirrors the `with` property of the arguments object that's already passed to on-load plugins. In addition, you can now pass `with` to the `resolve()` API call which will then forward that value on to all relevant plugins. Here's an example of a plugin that can now be written: ```js const examplePlugin = { name: 'Example plugin', setup(build) { build.onResolve({ filter: /.*/ }, args => { if (args.with.type === 'external') return { external: true } }) } } require('esbuild').build({ stdin: { contents: ` import foo from "./foo" with { type: "external" } foo() `, }, bundle: true, format: 'esm', write: false, plugins: [examplePlugin], }).then(result => { console.log(result.outputFiles[0].text) }) ``` - Formatting support for the `@position-try` rule ([#​3773](https://togithub.com/evanw/esbuild/issues/3773)) Chrome shipped this new CSS at-rule in version 125 as part of the [CSS anchor positioning API](https://developer.chrome.com/blog/anchor-positioning-api). With this release, esbuild now knows to expect a declaration list inside of the `@position-try` body block and will format it appropriately. - Always allow internal string import and export aliases ([#​3343](https://togithub.com/evanw/esbuild/issues/3343)) Import and export names can be string literals in ES2022+. Previously esbuild forbid any usage of these aliases when the target was below ES2022. Starting with this release, esbuild will only forbid such usage when the alias would otherwise end up in output as a string literal. String literal aliases that are only used internally in the bundle and are "compiled away" are no longer errors. This makes it possible to use string literal aliases with esbuild's `inject` feature even when the target is earlier than ES2022. ### [`v0.21.3`](https://togithub.com/evanw/esbuild/blob/HEAD/CHANGELOG.md#0213) [Compare Source](https://togithub.com/evanw/esbuild/compare/v0.21.2...v0.21.3) - Implement the decorator metadata proposal ([#​3760](https://togithub.com/evanw/esbuild/issues/3760)) This release implements the [decorator metadata proposal](https://togithub.com/tc39/proposal-decorator-metadata), which is a sub-proposal of the [decorators proposal](https://togithub.com/tc39/proposal-decorators). Microsoft shipped the decorators proposal in [TypeScript 5.0](https://devblogs.microsoft.com/typescript/announcing-typescript-5-0/#decorators) and the decorator metadata proposal in [TypeScript 5.2](https://devblogs.microsoft.com/typescript/announcing-typescript-5-2/#decorator-metadata), so it's important that esbuild also supports both of these features. Here's a quick example: ```js // Shim the "Symbol.metadata" symbol Symbol.metadata ??= Symbol('Symbol.metadata') const track = (_, context) => { (context.metadata.names ||= []).push(context.name) } class Foo { @​track foo = 1 @​track bar = 2 } // Prints ["foo", "bar"] console.log(Foo[Symbol.metadata].names) ``` **⚠️ WARNING ⚠️** This proposal has been marked as "stage 3" which means "recommended for implementation". However, it's still a work in progress and isn't a part of JavaScript yet, so keep in mind that any code that uses JavaScript decorator metadata may need to be updated as the feature continues to evolve. If/when that happens, I will update esbuild's implementation to match the specification. I will not be supporting old versions of the specification. - Fix bundled decorators in derived classes ([#​3768](https://togithub.com/evanw/esbuild/issues/3768)) In certain cases, bundling code that uses decorators in a derived class with a class body that references its own class name could previously generate code that crashes at run-time due to an incorrect variable name. This problem has been fixed. Here is an example of code that was compiled incorrectly before this fix: ```js class Foo extends Object { @​(x => x) foo() { return Foo } } console.log(new Foo().foo()) ``` - Fix `tsconfig.json` files inside symlinked directories ([#​3767](https://togithub.com/evanw/esbuild/issues/3767)) This release fixes an issue with a scenario involving a `tsconfig.json` file that `extends` another file from within a symlinked directory that uses the `paths` feature. In that case, the implicit `baseURL` value should be based on the real path (i.e. after expanding all symbolic links) instead of the original path. This was already done for other files that esbuild resolves but was not yet done for `tsconfig.json` because it's special-cased (the regular path resolver can't be used because the information inside `tsconfig.json` is involved in path resolution). Note that this fix no longer applies if the `--preserve-symlinks` setting is enabled. ### [`v0.21.2`](https://togithub.com/evanw/esbuild/blob/HEAD/CHANGELOG.md#0212) [Compare Source](https://togithub.com/evanw/esbuild/compare/v0.21.1...v0.21.2) - Correct `this` in field and accessor decorators ([#​3761](https://togithub.com/evanw/esbuild/issues/3761)) This release changes the value of `this` in initializers for class field and accessor decorators from the module-level `this` value to the appropriate `this` value for the decorated element (either the class or the instance). It was previously incorrect due to lack of test coverage. Here's an example of a decorator that doesn't work without this change: ```js const dec = () => function() { this.bar = true } class Foo { @​dec static foo } console.log(Foo.bar) // Should be "true" ``` - Allow `es2023` as a target environment ([#​3762](https://togithub.com/evanw/esbuild/issues/3762)) TypeScript recently [added `es2023`](https://togithub.com/microsoft/TypeScript/pull/58140) as a compilation target, so esbuild now supports this too. There is no difference between a target of `es2022` and `es2023` as far as esbuild is concerned since the 2023 edition of JavaScript doesn't introduce any new syntax features. ### [`v0.21.1`](https://togithub.com/evanw/esbuild/blob/HEAD/CHANGELOG.md#0211) - Fix a regression with `--keep-names` ([#​3756](https://togithub.com/evanw/esbuild/issues/3756)) The previous release introduced a regression with the `--keep-names` setting and object literals with `get`/`set` accessor methods, in which case the generated code contained syntax errors. This release fixes the regression: ```js // Original code x = { get y() {} } // Output from version 0.21.0 (with --keep-names) x = { get y: /* @​__PURE__ */ __name(function() { }, "y") }; // Output from this version (with --keep-names) x = { get y() { } }; ``` </details> <details> <summary>alecthomas/assert (github.com/alecthomas/assert/v2)</summary> ### [`v2.10.0`](https://togithub.com/alecthomas/assert/compare/v2.9.0...v2.10.0) [Compare Source](https://togithub.com/alecthomas/assert/compare/v2.9.0...v2.10.0) ### [`v2.9.0`](https://togithub.com/alecthomas/assert/compare/v2.8.1...v2.9.0) [Compare Source](https://togithub.com/alecthomas/assert/compare/v2.8.1...v2.9.0) ### [`v2.8.1`](https://togithub.com/alecthomas/assert/compare/v2.8.0...v2.8.1) [Compare Source](https://togithub.com/alecthomas/assert/compare/v2.8.0...v2.8.1) ### [`v2.8.0`](https://togithub.com/alecthomas/assert/compare/v2.7.0...v2.8.0) [Compare Source](https://togithub.com/alecthomas/assert/compare/v2.7.0...v2.8.0) </details> <details> <summary>alecthomas/chroma (github.com/alecthomas/chroma/v2)</summary> ### [`v2.14.0`](https://togithub.com/alecthomas/chroma/releases/tag/v2.14.0) [Compare Source](https://togithub.com/alecthomas/chroma/compare/v2.13.0...v2.14.0) #### Changelog - [`1e983e7`](https://togithub.com/alecthomas/chroma/commit/1e983e7) lexers/cue: support CUE attributes ([#​961](https://togithub.com/alecthomas/chroma/issues/961)) - [`9347b55`](https://togithub.com/alecthomas/chroma/commit/9347b55) Add Gleam syntax highlighting ([#​959](https://togithub.com/alecthomas/chroma/issues/959)) - [`6b7ffe1`](https://togithub.com/alecthomas/chroma/commit/6b7ffe1) chore(styles): add tokyonight inspired styles ([#​957](https://togithub.com/alecthomas/chroma/issues/957)) - [`736c0ea`](https://togithub.com/alecthomas/chroma/commit/736c0ea) Typescript: Several fixes ([#​952](https://togithub.com/alecthomas/chroma/issues/952)) - [`e5c25d0`](https://togithub.com/alecthomas/chroma/commit/e5c25d0) Org: Keep all newlines ([#​951](https://togithub.com/alecthomas/chroma/issues/951)) - [`d07caa4`](https://togithub.com/alecthomas/chroma/commit/d07caa4) chore(deps): update module github.com/alecthomas/assert/v2 to v2.7.0 ([#​949](https://togithub.com/alecthomas/chroma/issues/949)) - [`5f83664`](https://togithub.com/alecthomas/chroma/commit/5f83664) Vue: Handle more edge cases ([#​950](https://togithub.com/alecthomas/chroma/issues/950)) - [`32c053f`](https://togithub.com/alecthomas/chroma/commit/32c053f) chore(deps): update all non-major dependencies ([#​948](https://togithub.com/alecthomas/chroma/issues/948)) - [`2580aaa`](https://togithub.com/alecthomas/chroma/commit/2580aaa) Add Bazel bzlmod support into Python lexer ([#​947](https://togithub.com/alecthomas/chroma/issues/947)) </details> <details> <summary>golang/go (go)</summary> ### [`v1.22.3`](https://togithub.com/golang/go/compare/go1.22.2...go1.22.3) ### [`v1.22.2`](https://togithub.com/golang/go/compare/go1.22.1...go1.22.2) </details> <details> <summary>goreleaser/goreleaser (goreleaser)</summary> ### [`v1.26.2`](https://togithub.com/goreleaser/goreleaser/releases/tag/v1.26.2) #### Changelog ##### Bug fixes - [`b3d6460`]( |
||
renovate[bot]
|
32c053f501
|
chore(deps): update all non-major dependencies (#948)
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Type | Update | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---|---|---| | [esbuild](https://togithub.com/evanw/esbuild) | | patch | `0.20.1` -> `0.20.2` | [![age](https://developer.mend.io/api/mc/badges/age/hermit/esbuild/0.20.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/hermit/esbuild/0.20.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/hermit/esbuild/0.20.1/0.20.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/hermit/esbuild/0.20.1/0.20.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [github.com/alecthomas/chroma/v2](https://togithub.com/alecthomas/chroma) | require | minor | `v2.12.0` -> `v2.13.0` | [![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2falecthomas%2fchroma%2fv2/v2.13.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/go/github.com%2falecthomas%2fchroma%2fv2/v2.13.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/go/github.com%2falecthomas%2fchroma%2fv2/v2.12.0/v2.13.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2falecthomas%2fchroma%2fv2/v2.12.0/v2.13.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>evanw/esbuild (esbuild)</summary> ### [`v0.20.2`](https://togithub.com/evanw/esbuild/blob/HEAD/CHANGELOG.md#0202) [Compare Source](https://togithub.com/evanw/esbuild/compare/v0.20.1...v0.20.2) - Support TypeScript experimental decorators on `abstract` class fields ([#​3684](https://togithub.com/evanw/esbuild/issues/3684)) With this release, you can now use TypeScript experimental decorators on `abstract` class fields. This was silently compiled incorrectly in esbuild 0.19.7 and below, and was an error from esbuild 0.19.8 to esbuild 0.20.1. Code such as the following should now work correctly: ```ts // Original code const log = (x: any, y: string) => console.log(y) abstract class Foo { @​log abstract foo: string } new class extends Foo { foo = '' } // Old output (with --loader=ts --tsconfig-raw={\"compilerOptions\":{\"experimentalDecorators\":true}}) const log = (x, y) => console.log(y); class Foo { } new class extends Foo { foo = ""; }(); // New output (with --loader=ts --tsconfig-raw={\"compilerOptions\":{\"experimentalDecorators\":true}}) const log = (x, y) => console.log(y); class Foo { } __decorateClass([ log ], Foo.prototype, "foo", 2); new class extends Foo { foo = ""; }(); ``` - JSON loader now preserves `__proto__` properties ([#​3700](https://togithub.com/evanw/esbuild/issues/3700)) Copying JSON source code into a JavaScript file will change its meaning if a JSON object contains the `__proto__` key. A literal `__proto__` property in a JavaScript object literal sets the prototype of the object instead of adding a property named `__proto__`, while a literal `__proto__` property in a JSON object literal just adds a property named `__proto__`. With this release, esbuild will now work around this problem by converting JSON to JavaScript with a computed property key in this case: ```js // Original code import data from 'data:application/json,{"__proto__":{"fail":true}}' if (Object.getPrototypeOf(data)?.fail) throw 'fail' // Old output (with --bundle) (() => { // <data:application/json,{"__proto__":{"fail":true}}> var json_proto_fail_true_default = { __proto__: { fail: true } }; // entry.js if (Object.getPrototypeOf(json_proto_fail_true_default)?.fail) throw "fail"; })(); // New output (with --bundle) (() => { // <data:application/json,{"__proto__":{"fail":true}}> var json_proto_fail_true_default = { ["__proto__"]: { fail: true } }; // example.mjs if (Object.getPrototypeOf(json_proto_fail_true_default)?.fail) throw "fail"; })(); ``` - Improve dead code removal of `switch` statements ([#​3659](https://togithub.com/evanw/esbuild/issues/3659)) With this release, esbuild will now remove `switch` statements in branches when minifying if they are known to never be evaluated: ```js // Original code if (true) foo(); else switch (bar) { case 1: baz(); break } // Old output (with --minify) if(1)foo();else switch(bar){case 1:} // New output (with --minify) foo(); ``` - Empty enums should behave like an object literal ([#​3657](https://togithub.com/evanw/esbuild/issues/3657)) TypeScript allows you to create an empty enum and add properties to it at run time. While people usually use an empty object literal for this instead of a TypeScript enum, esbuild's enum transform didn't anticipate this use case and generated `undefined` instead of `{}` for an empty enum. With this release, you can now use an empty enum to generate an empty object literal. ```ts // Original code enum Foo {} // Old output (with --loader=ts) var Foo = /* @​__PURE__ */ ((Foo2) => { })(Foo || {}); // New output (with --loader=ts) var Foo = /* @​__PURE__ */ ((Foo2) => { return Foo2; })(Foo || {}); ``` - Handle Yarn Plug'n'Play edge case with `tsconfig.json` ([#​3698](https://togithub.com/evanw/esbuild/issues/3698)) Previously a `tsconfig.json` file that `extends` another file in a package with an `exports` map failed to work when Yarn's Plug'n'Play resolution was active. This edge case should work now starting with this release. - Work around issues with Deno 1.31+ ([#​3682](https://togithub.com/evanw/esbuild/issues/3682)) Version 0.20.0 of esbuild changed how the esbuild child process is run in esbuild's API for Deno. Previously it used `Deno.run` but that API is being removed in favor of `Deno.Command`. As part of this change, esbuild is now calling the new `unref` function on esbuild's long-lived child process, which is supposed to allow Deno to exit when your code has finished running even though the child process is still around (previously you had to explicitly call esbuild's `stop()` function to terminate the child process for Deno to be able to exit). However, this introduced a problem for Deno's testing API which now fails some tests that use esbuild with `error: Promise resolution is still pending but the event loop has already resolved`. It's unclear to me why this is happening. The call to `unref` was recommended by someone on the Deno core team, and calling Node's equivalent `unref` API has been working fine for esbuild in Node for a long time. It could be that I'm using it incorrectly, or that there's some reference counting and/or garbage collection bug in Deno's internals, or that Deno's `unref` just works differently than Node's `unref`. In any case, it's not good for Deno tests that use esbuild to be failing. In this release, I am removing the call to `unref` to fix this issue. This means that you will now have to call esbuild's `stop()` function to allow Deno to exit, just like you did before esbuild version 0.20.0 when this regression was introduced. Note: This regression wasn't caught earlier because Deno doesn't seem to fail tests that have outstanding `setTimeout` calls, which esbuild's test harness was using to enforce a maximum test runtime. Adding a `setTimeout` was allowing esbuild's Deno tests to succeed. So this regression doesn't necessarily apply to all people using tests in Deno. </details> <details> <summary>alecthomas/chroma (github.com/alecthomas/chroma/v2)</summary> ### [`v2.13.0`](https://togithub.com/alecthomas/chroma/releases/tag/v2.13.0) [Compare Source](https://togithub.com/alecthomas/chroma/compare/v2.12.0...v2.13.0) ##### Changelog - [`bd47355`](https://togithub.com/alecthomas/chroma/commit/bd47355) fix: include compress state in style cache key - [`1235bbf`](https://togithub.com/alecthomas/chroma/commit/1235bbf) chore(deps): update all non-major dependencies ([#​944](https://togithub.com/alecthomas/chroma/issues/944)) - [`4e60c81`](https://togithub.com/alecthomas/chroma/commit/4e60c81) C#: Allow for empty comments ([#​943](https://togithub.com/alecthomas/chroma/issues/943)) - [`fe5dde8`](https://togithub.com/alecthomas/chroma/commit/fe5dde8) Add Lexer for NDISASM ([#​933](https://togithub.com/alecthomas/chroma/issues/933)) - [`6dd9f26`](https://togithub.com/alecthomas/chroma/commit/6dd9f26) feat: introduce a LRU compiled style cache for the HTML formatter ([#​938](https://togithub.com/alecthomas/chroma/issues/938)) - [`898d467`](https://togithub.com/alecthomas/chroma/commit/898d467) lexers/cue: support definitions and dollars in field names ([#​935](https://togithub.com/alecthomas/chroma/issues/935)) - [`0f92de4`](https://togithub.com/alecthomas/chroma/commit/0f92de4) chore(deps): update all non-major dependencies ([#​934](https://togithub.com/alecthomas/chroma/issues/934)) - [`381050b`](https://togithub.com/alecthomas/chroma/commit/381050b) Major updates to Caddyfile lexer ([#​932](https://togithub.com/alecthomas/chroma/issues/932)) - [`e9292e6`](https://togithub.com/alecthomas/chroma/commit/e9292e6) chore(deps): update dependency goreleaser to v1.24.0 ([#​925](https://togithub.com/alecthomas/chroma/issues/925)) - [`ddbae13`](https://togithub.com/alecthomas/chroma/commit/ddbae13) chore: upgrade Go - [`7ce2caf`](https://togithub.com/alecthomas/chroma/commit/7ce2caf) Fix lexers check when built with newer Go ([#​928](https://togithub.com/alecthomas/chroma/issues/928)) - [`506e36f`](https://togithub.com/alecthomas/chroma/commit/506e36f) fix(lexers/go): "~" is a valid token ([#​926](https://togithub.com/alecthomas/chroma/issues/926)) - [`f4788c0`](https://togithub.com/alecthomas/chroma/commit/f4788c0) docs: add import to README - [`39115eb`](https://togithub.com/alecthomas/chroma/commit/39115eb) chore(deps): update dependency esbuild to v0.20.0 ([#​921](https://togithub.com/alecthomas/chroma/issues/921)) - [`4c6fdb1`](https://togithub.com/alecthomas/chroma/commit/4c6fdb1) Add .avsc to JSON lexer ([#​920](https://togithub.com/alecthomas/chroma/issues/920)) - [`ee60f7e`](https://togithub.com/alecthomas/chroma/commit/ee60f7e) Add missing token types for Rego + add Rego to README ([#​919](https://togithub.com/alecthomas/chroma/issues/919)) - [`ae36e63`](https://togithub.com/alecthomas/chroma/commit/ae36e63) Add support for Rego syntax ([#​918](https://togithub.com/alecthomas/chroma/issues/918)) - [`d7a7dd3`](https://togithub.com/alecthomas/chroma/commit/d7a7dd3) chore(deps): update module github.com/alecthomas/assert/v2 to v2.5.0 ([#​917](https://togithub.com/alecthomas/chroma/issues/917)) - [`c31293c`](https://togithub.com/alecthomas/chroma/commit/c31293c) chore(deps): update dependency go to v1.21.6 ([#​915](https://togithub.com/alecthomas/chroma/issues/915)) - [`ebc34cf`](https://togithub.com/alecthomas/chroma/commit/ebc34cf) fix file extension typo, remove redundent parens ([#​914](https://togithub.com/alecthomas/chroma/issues/914)) - [`641b06f`](https://togithub.com/alecthomas/chroma/commit/641b06f) Fix type operators not being recognised in Haskell ([#​913](https://togithub.com/alecthomas/chroma/issues/913)) - [`3ef9475`](https://togithub.com/alecthomas/chroma/commit/3ef9475) chore(deps): update dependency watchexec to v1.25.1 ([#​912](https://togithub.com/alecthomas/chroma/issues/912)) - [`23368be`](https://togithub.com/alecthomas/chroma/commit/23368be) styles(catpuccin/gh-dark): LineHighlight grp ([#​911](https://togithub.com/alecthomas/chroma/issues/911)) - [`a8704a8`](https://togithub.com/alecthomas/chroma/commit/a8704a8) Add lexer for RPMSpec ([#​907](https://togithub.com/alecthomas/chroma/issues/907)) - [`eb47752`](https://togithub.com/alecthomas/chroma/commit/eb47752) Add lexer for Promela ([#​906](https://togithub.com/alecthomas/chroma/issues/906)) - [`3f395c9`](https://togithub.com/alecthomas/chroma/commit/3f395c9) chore(deps): update all non-major dependencies ([#​905](https://togithub.com/alecthomas/chroma/issues/905)) - [`2018c2f`](https://togithub.com/alecthomas/chroma/commit/2018c2f) chore(deps): update all non-major dependencies ([#​904](https://togithub.com/alecthomas/chroma/issues/904)) - [`016768b`](https://togithub.com/alecthomas/chroma/commit/016768b) Add desktop entry lexer ([#​903](https://togithub.com/alecthomas/chroma/issues/903)) - [`f130045`](https://togithub.com/alecthomas/chroma/commit/f130045) chore(deps): update dependency watchexec to v1.24.1 ([#​901](https://togithub.com/alecthomas/chroma/issues/901)) - [`9670d34`](https://togithub.com/alecthomas/chroma/commit/9670d34) chore(deps): update actions/checkout action to v4 ([#​899](https://togithub.com/alecthomas/chroma/issues/899)) - [`ad03817`](https://togithub.com/alecthomas/chroma/commit/ad03817) chore(deps): update all non-major dependencies ([#​898](https://togithub.com/alecthomas/chroma/issues/898)) - [`76039a5`](https://togithub.com/alecthomas/chroma/commit/76039a5) chore(deps): update all non-major dependencies ([#​897](https://togithub.com/alecthomas/chroma/issues/897)) - [`678b799`](https://togithub.com/alecthomas/chroma/commit/678b799) Add a lexer for the Materialize SQL dialect ([#​896](https://togithub.com/alecthomas/chroma/issues/896)) </details> --- ### Configuration 📅 **Schedule**: Branch creation - "before 4am on Monday" (UTC), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/alecthomas/chroma). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4yNDUuMCIsInVwZGF0ZWRJblZlciI6IjM3LjI0NS4wIiwidGFyZ2V0QnJhbmNoIjoibWFzdGVyIn0=--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> |
||
renovate[bot]
|
1235bbf2ce
|
chore(deps): update all non-major dependencies (#944) | ||
renovate[bot]
|
76039a532f
|
chore(deps): update all non-major dependencies (#897)
* chore(deps): update all non-major dependencies * fix: fixes for test and lint Test was slow because we were deep-comparing lexers. This is unnecessary as we can just shallow compare. --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Alec Thomas <alec@swapoff.org> |
||
Alec Thomas
|
4dd2cbef84 |
fix: bump to latest dclark/regexp2
Fixes #805 |
||
Toshimaru
|
9864526122
|
deps: update go modules (#810) | ||
JakobDev
|
31310888c4
|
Fix Playground on Windows (#758) | ||
toshimaru
|
db073d869d |
deps: Bump modules for cmd/chromad
- alecthomas/kong - alecthomas/kong-hcl - gorilla/csrf - gorilla/handlers - gorilla/mux |
||
Alec Thomas
|
d330b760dc | feat: support sharing in playground | ||
Alec Thomas
|
40b7a9135a | Upgrade project to Go 1.19 and switch to alecthomas/assert/v2 | ||
Alec Thomas
|
4dfc2caf03 | refactor: run go mod tidy on chromad | ||
Alec Thomas
|
cc2dd5b8ad |
Version 2 of Chroma
This cleans up the API in general, removing a bunch of deprecated stuff, cleaning up circular imports, etc. But the biggest change is switching to an optional XML format for the regex lexer. Having lexers defined only in Go is not ideal for a couple of reasons. Firstly, it impedes a significant portion of contributors who use Chroma in Hugo, but don't know Go. Secondly, it bloats the binary size of any project that imports Chroma. Why XML? YAML is an abomination and JSON is not human editable. XML also compresses very well (eg. Go template lexer XML compresses from 3239 bytes to 718). Why a new syntax format? All major existing formats rely on the Oniguruma regex engine, which is extremely complex and for which there is no Go port. Why not earlier? Prior to the existence of fs.FS this was not a viable option. Benchmarks: $ hyperfine --warmup 3 \ './chroma.master --version' \ './chroma.xml-pre-opt --version' \ './chroma.xml --version' Benchmark 1: ./chroma.master --version Time (mean ± σ): 5.3 ms ± 0.5 ms [User: 3.6 ms, System: 1.4 ms] Range (min … max): 4.2 ms … 6.6 ms 233 runs Benchmark 2: ./chroma.xml-pre-opt --version Time (mean ± σ): 50.6 ms ± 0.5 ms [User: 52.4 ms, System: 3.6 ms] Range (min … max): 49.2 ms … 51.5 ms 51 runs Benchmark 3: ./chroma.xml --version Time (mean ± σ): 6.9 ms ± 1.1 ms [User: 5.1 ms, System: 1.5 ms] Range (min … max): 5.7 ms … 19.9 ms 196 runs Summary './chroma.master --version' ran 1.30 ± 0.23 times faster than './chroma.xml --version' 9.56 ± 0.83 times faster than './chroma.xml-pre-opt --version' A slight increase in init time, but I think this is okay given the increase in flexibility. And binary size difference: $ du -h lexers.test* $ du -sh chroma* 951371ms 8.8M chroma.master 7.8M chroma.xml 7.8M chroma.xml-pre-opt Benchmarks: $ hyperfine --warmup 3 \ './chroma.master --version' \ './chroma.xml-pre-opt --version' \ './chroma.xml --version' Benchmark 1: ./chroma.master --version Time (mean ± σ): 5.3 ms ± 0.5 ms [User: 3.6 ms, System: 1.4 ms] Range (min … max): 4.2 ms … 6.6 ms 233 runs Benchmark 2: ./chroma.xml-pre-opt --version Time (mean ± σ): 50.6 ms ± 0.5 ms [User: 52.4 ms, System: 3.6 ms] Range (min … max): 49.2 ms … 51.5 ms 51 runs Benchmark 3: ./chroma.xml --version Time (mean ± σ): 6.9 ms ± 1.1 ms [User: 5.1 ms, System: 1.5 ms] Range (min … max): 5.7 ms … 19.9 ms 196 runs Summary './chroma.master --version' ran 1.30 ± 0.23 times faster than './chroma.xml --version' 9.56 ± 0.83 times faster than './chroma.xml-pre-opt --version' Incompatible changes: - (*RegexLexer).SetAnalyser: changed from func(func(text string) float32) *RegexLexer to func(func(text string) float32) Lexer - (*TokenType).UnmarshalJSON: removed - Lexer.AnalyseText: added - Lexer.SetAnalyser: added - Lexer.SetRegistry: added - MustNewLazyLexer: removed - MustNewLexer: changed from func(*Config, Rules) *RegexLexer to func(*Config, func() Rules) *RegexLexer - Mutators: changed from func(...Mutator) MutatorFunc to func(...Mutator) Mutator - NewLazyLexer: removed - NewLexer: changed from func(*Config, Rules) (*RegexLexer, error) to func(*Config, func() Rules) (*RegexLexer, error) - Pop: changed from func(int) MutatorFunc to func(int) Mutator - Push: changed from func(...string) MutatorFunc to func(...string) Mutator - TokenType.MarshalJSON: removed - Using: changed from func(Lexer) Emitter to func(string) Emitter - UsingByGroup: changed from func(func(string) Lexer, int, int, ...Emitter) Emitter to func(int, int, ...Emitter) Emitter |
||
Alec Thomas
|
0e8972ef9b | Fix chromad build. | ||
Alec Thomas
|
c44c690de2 | Switch chromad to go:embed and show version. | ||
Alec Thomas
|
7410d4a2dc | Update chromad modules. | ||
Alec Thomas
|
bac74c1016 | Fix Makefile. | ||
Alec Thomas
|
9fb54c5f75 |
Add separate go module for ./cmd/chromad.
Fixes #261. |
||
Alec Thomas
|
2d34ebacdb | Simplify configuration of HTML call. | ||
Bjørn Erik Pedersen
|
5921c52787 |
Add bool argument to WithClasses, WithLineNumbers etc.
This allows the boolean options to be reconfigured, e.g: ```go options := getOptions() options = append(options, html.WithLineNumbers(true)) ``` Fixes #301 |
||
Alec Thomas
|
bbbfbe4e7a | Update to more recent golangci-lint. | ||
Alec Thomas
|
3411213e25 | Temporarily use go.rice fork with correct asset timestamping/versioning. | ||
Alec Thomas
|
9fbb21283d | Render full HTML. | ||
Alec Thomas
|
89e7ddc5d9 | Disable spellchecking/autocomplete. | ||
Alec Thomas
|
5da2819c7d | Add cache-busting version. | ||
Alec Thomas
|
c86a26959c | Add info block. | ||
Alec Thomas
|
aa71d61cc0 | Only allow POST to /api/render. | ||
Alec Thomas
|
ffa8a4f67f | CORS support + raw HTML view + more. | ||
Alec Thomas
|
bdb587cd37 | Make playground completely dynamic. | ||
Alec Thomas
|
2332264124 | Add CSRF support to chromad. | ||
Alec Thomas
|
7a7fde259b | Split out chromad resources. | ||
Alec Thomas
|
91b44ffd76 | Lint isses. | ||
Alec Thomas
|
10cee2ee79 |
Add Chroma playground.
Found here: https://swapoff.org/chroma/playground |