-
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.
feat: add script for renaming project, and readme
- Loading branch information
Showing
2 changed files
with
32 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Template for CEUR Articles | ||
|
||
## How to use | ||
|
||
0. Create a repo using this template | ||
1. `git clone --recursive YOUR_REPO_URL` | ||
2. `cd YOUR_REPO_NAME` | ||
3. `./rename-template.sh YOUR_REPO_NAME` | ||
4. Commit & push | ||
5. Write your paper | ||
6. Recall to update the version commands in the `.tex` file |
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,21 @@ | ||
#!bash | ||
|
||
CWD=`pwd` | ||
DIR_NAME=${CWD##*/} | ||
|
||
NEW_NAME=${1:-$DIR_NAME} | ||
|
||
if [[ -z "$NEW_NAME" ]]; then | ||
echo "Must provide a new name as argument" 1>&2 | ||
exit 1 | ||
fi | ||
|
||
for EXT in tex sty bib; do | ||
mv ceur-article-template.$EXT $NEW_NAME.$EXT | ||
done | ||
|
||
for FILE in `ls $NEW_NAME.{tex,sty,bib} .gitignore .github/workflows/*.yml`; do | ||
sed -i '.bak' -e "s/ceur-article-template/$NEW_NAME/g" $FILE | ||
done | ||
|
||
rm *.bak .github/workflows/*.bak *.sh |