mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
Adjust to ensure previews load isolated code (#1547)
Ensure previews use the plugin script from the tree instead of the common one for latest and version releases
This commit is contained in:
@@ -38,6 +38,7 @@ jobs:
|
|||||||
# avoid look up of API as it doesn't work from within actions without exposing the GITHUB_TOKEN here which is a security risk
|
# avoid look up of API as it doesn't work from within actions without exposing the GITHUB_TOKEN here which is a security risk
|
||||||
cat <<EOF >> docs/_config.yml
|
cat <<EOF >> docs/_config.yml
|
||||||
repository_nwo: vagrant-libvirt/vagrant-libvirt
|
repository_nwo: vagrant-libvirt/vagrant-libvirt
|
||||||
|
plugin_script_base_path: /${REPO_NAME}/pr-preview/pr-${PR_NUMBER}
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
BUNDLE_GEMFILE=./docs/Gemfile bundle install
|
BUNDLE_GEMFILE=./docs/Gemfile bundle install
|
||||||
|
|||||||
@@ -1,7 +1,9 @@
|
|||||||
<script src="{% asset "js/site_constants.js" @path %}"></script>
|
<script src="{% asset "js/site_constants.js" @path %}"></script>
|
||||||
<div id="plugin-version-menu" class="site-footer"></div>
|
<div id="plugin-version-menu" class="site-footer"></div>
|
||||||
{%- assign basePath = "" %}
|
{%- assign basePath = "" %}
|
||||||
{%- if site.baseurl.size != 0 %}
|
{%- if site.plugin_script_base_path %}
|
||||||
|
{%- assign basePath = site.plugin_script_base_path %}
|
||||||
|
{%- elsif site.baseurl.size != 0 %}
|
||||||
{%- assign basePath = "/vagrant-libvirt" %}
|
{%- assign basePath = "/vagrant-libvirt" %}
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
<script src="{{ basePath }}/assets/js/plugin_versions_menu.js"></script>
|
<script src="{{ basePath }}/assets/js/plugin_versions_menu.js"></script>
|
||||||
|
|||||||
Reference in New Issue
Block a user