Skip to content

Commit

Permalink
Merge pull request #629 from nicosomb/remove-env-config
Browse files Browse the repository at this point in the history
Removed .env configuration
  • Loading branch information
nicosomb authored Jul 4, 2024
2 parents 31b651a + 103cdde commit 063b4dc
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,4 +96,4 @@ jobs:
upload_url: ${{ steps.release_info.outputs.upload_url }}
asset_path: ./${{ github.event.repository.name }}/${{ github.event.repository.name }}.zip
asset_name: ${{ github.event.repository.name }}.zip
asset_content_type: application/zip
asset_content_type: application/zip
2 changes: 1 addition & 1 deletion templates/catalog/_partials/miniatures/product.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@
{/block}
</div>

{if $product.add_to_cart_url && $product.product_type !== 'combinations'}
{if $product.add_to_cart_url}
<form action="{$urls.pages.cart}" method="post" class="d-flex flex-wrap flex-md-nowrap gap-3 align-items-center mt-3">
<input type="hidden" value="{$product.id_product}" name="id_product">

Expand Down
13 changes: 5 additions & 8 deletions webpack/webpack.vars.js
Original file line number Diff line number Diff line change
@@ -1,21 +1,18 @@
const fs = require('fs');
const path = require('path');

const themeDev = path.resolve(__dirname, '../src');

const envFilePath = './webpack/.env';

if (fs.existsSync(envFilePath)) {
require('dotenv').config({path: envFilePath});
} else {
console.error('\x1b[41m\x1b[37m%s\x1b[0m', 'Your .env file not exits. Read getting started section in documentation for more information https://github.com/PrestaShop/hummingbird?tab=readme-ov-file#how-to-build-assets/.');
process.exit();
}

const {
PORT: port,
PUBLIC_PATH: publicPath,
SERVER_ADDRESS: serverAddress,
SITE_URL: siteURL,
PORT: port = null,
PUBLIC_PATH: publicPath = null,
SERVER_ADDRESS: serverAddress = null,
SITE_URL: siteURL = null,
} = process.env;

const entriesArray = {
Expand Down

0 comments on commit 063b4dc

Please sign in to comment.