Feature Request - Loop by pattern matching.
- Ngôn ngữ chính
- Go
- Star
- 907
- Fork
- 96
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
I have a case where I need to create multiple entries in a config file based on the existence of environment variables. (its for a reverse proxy and I want to be able to add new entries simply by adding additional environment variables)
Something like:
**Env Vars:**
```
SRVCS_FIRST_HOSTNAME=sample.service.com
SRVCS_FIRST_DEST=internal.server.name
SRVCS_SECOND_HOSTNAME=second.service.com
SRVCS_SECOND_DEST=internal2.server.name
```
**Template:**
```
${SRVCS_*_<
host: ${HOSTNAME}
destination: ${DEST}
>}
```
**Result:**
```
host: sample.service.com
destination: internal.server.name
host: second.service.com
destination: internal2.server.name
```
Any thoughts on this idea? _I_ think it'd be pretty handy.
Hướng dẫn đóng góp
Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này
Đánh giá
Issue này chưa được đánh giá.