generated from blueberry-team/blueberry_template_deprecated
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0c7d471
commit c368a9d
Showing
3 changed files
with
42 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
# PowerShell 스크립트로 .env 파일 생성 | ||
|
||
param ( | ||
[string]$TargetDir | ||
) | ||
|
||
# 디버깅 출력 | ||
Write-Output "Target Directory: $TargetDir" | ||
|
||
# 빈 문자열이 전달되었는지 확인 | ||
if ([string]::IsNullOrWhiteSpace($TargetDir)) { | ||
Write-Error "Target directory is not specified or is empty." | ||
exit 1 | ||
} | ||
|
||
# .env 파일 내용 | ||
$envContent = @" | ||
# please replace 'your_api_key_here' with your actual API key | ||
API_KEY=your_api_key_here | ||
# Other environment variables can be added here | ||
"@ | ||
|
||
# .env 파일 생성 | ||
$envFilePath = Join-Path -Path $TargetDir -ChildPath ".env" | ||
Write-Output "Creating .env file at: $envFilePath" | ||
|
||
# UTF-8 인코딩으로 파일 생성 | ||
$envContent | Out-File -FilePath $envFilePath -Encoding utf8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
#!/bin/bash | ||
|
||
# .env 파일 생성 | ||
echo "# API 키를 추가해주세요." >> .env | ||
echo "API_KEY=your_api_key_here" >> .env | ||
echo "# Other environment variables can be added here" >> .env | ||
# .env 파일 생성 경로 | ||
TARGET_DIR=$1 | ||
|
||
# 파일 생성 후 권한 변경 (선택 사항) | ||
chmod 600 .env | ||
# .env 파일 생성 | ||
echo "# API 키를 추가해주세요." > "$TARGET_DIR/.env" | ||
echo "API_KEY=your_api_key_here" >> "$TARGET_DIR/.env" | ||
echo "# Other environment variables can be added here" >> "$TARGET_DIR/.env" |