DEV Community

Clavin June
Clavin June

Posted on • Originally published at clavinjune.dev on

2 1

Include Dotenv File to Makefile

Sunday Snippet #17 include dotenv file to makefile

Directory Structure

$ tree -a .
.
├── .env
└── Makefile

0 directories, 2 files
Enter fullscreen mode Exit fullscreen mode

Dotenv File

$ cat .env
FOO=12345
Enter fullscreen mode Exit fullscreen mode

Makefile

$ cat Makefile
include .env

example:
    @echo "${FOO}"
$ make example
12345
Enter fullscreen mode Exit fullscreen mode

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay