Skip to content

Commit

Permalink
Merge pull request #36 from the-markup/look-no-composer
Browse files Browse the repository at this point in the history
Don't require composer autoload
  • Loading branch information
BatMiles committed Jun 5, 2024
2 parents d563754 + 3a5a2c8 commit 83a57b7
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .distignore
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ webpack.config.js
wp-cli.local.yml
yarn.lock
tests
vendor/*
vendor
node_modules
*.sql
*.tar.gz
Expand Down
3 changes: 2 additions & 1 deletion bin/release
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ dir="$( cd "$(dirname "$( dirname "${BASH_SOURCE[0]}" )" )" >/dev/null 2>&1 && p
version="$(cat "$dir/readme.txt" | grep "Stable tag: " | cut -c 13-)"
svn="$1"



if [ -d "$svn/tags/$version" ] ; then
echo "Error: $svn/tags/$version already exists"
exit 1
Expand All @@ -27,7 +29,6 @@ echo "Creating $svn/tags/$version..."
mkdir "$svn/tags/$version"
rsync --recursive \
--verbose \
--include="vendor/autoload.php" \
--exclude-from=".distignore" \
"$dir/" \
"$svn/tags/$version/"
Expand Down
8 changes: 8 additions & 0 deletions smol-links.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,14 @@

if (file_exists(__DIR__ . '/vendor/autoload.php')) {
require_once(__DIR__ . '/vendor/autoload.php');
} else {
require_once __DIR__ . '/src/API.php';
require_once __DIR__ . '/src/Editor.php';
require_once __DIR__ . '/src/Manager.php';
require_once __DIR__ . '/src/Options.php';
require_once __DIR__ . '/src/Plugin.php';
require_once __DIR__ . '/src/Settings.php';
require_once __DIR__ . '/src/ShlinkException.php';
}

add_action('plugins_loaded', function() {
Expand Down

0 comments on commit 83a57b7

Please sign in to comment.