From f2cd011be225a44ad6c89b4ff6e118c7a8e354c8 Mon Sep 17 00:00:00 2001 From: Aaron Francis Date: Thu, 17 Jun 2021 10:55:15 -0500 Subject: [PATCH] Get token from env. Changelog. --- CHANGELOG.md | 11 +++++++++++ src/Commands/InstallTorchlight.php | 5 +++-- 2 files changed, 14 insertions(+), 2 deletions(-) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..46511f1 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,11 @@ +# Changelog + +## Unreleased + +## 0.1.1 - 2021-06-17 + +### Changed +- The `torchlight.php` config file now defaults to an environment variable for the token. + +### Fixed +- Torchlight caused an error if there were no code blocks whatsoever. \ No newline at end of file diff --git a/src/Commands/InstallTorchlight.php b/src/Commands/InstallTorchlight.php index b0cf8dc..0a200b3 100644 --- a/src/Commands/InstallTorchlight.php +++ b/src/Commands/InstallTorchlight.php @@ -51,8 +51,9 @@ protected function stub() // https://torchlight.dev/themes, or you can provide your own. 'theme' => 'material-theme-palenight', - // Your API token from torchlight.dev. - 'token' => '', + // Your API token from torchlight.dev. You can set it as an ENV variable + // (shown below), or just hardcode it if your repo is private. + 'token' => getenv('TORCHLIGHT_API_TOKEN'), // If you want to register the blade directives, set this to true. 'blade_components' => true,