[feature request] allow mounting custom folders

I’d like to mount some custom folders from modules, such as the functions folder (Cloudflare Pages functions), currently, it’s not allowed.

mount target must be one of: [archetypes assets content data i18n layouts static

With this feature, we can reuse the functions via modules on multiple sites, this way is more easiler than git submodule or copy-and-paste (the later won’t be considered, since it’s hard to maintain).

I would also like to see this implemented. My use case would be to include GitHub Actions workflows.

Currently, all of my sites include the following file, which I would prefer to be mounted via a Hugo Module.

.github/workflows/cloudflare-pages.yml

name: Deploy Hugo Site to Cloudflare Pages

on:
  push:
    branches:
      - main
      - stage
  workflow_dispatch:

jobs:
  cloudflare-pages:
    uses: simonheimlicher/claris-gh-actions/.github/workflows/cloudflare-pages.yml@main
    with:
      hugo_version: '0.121.2'
      cloudflare_project_name: ${{ vars.CLOUDFLARE_PROJECT_NAME }}
      cloudflare_stage_project_name: ${{ vars.CLOUDFLARE_STAGE_PROJECT_NAME }}
    secrets:
      HUGO_CLARIS_AUTHOR_EMAIL: ${{ secrets.HUGO_CLARIS_AUTHOR_EMAIL }}
      CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }}
      CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
      CLOUDFLARE_STAGE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_STAGE_ACCOUNT_ID }}
    permissions:
      contents: read
      deployments: write
  
1 Like