close to prerelase
This commit is contained in:
parent
e55fbb5b67
commit
31022358ed
181 changed files with 2118 additions and 141 deletions
38
scripts/add_person.sh
Executable file
38
scripts/add_person.sh
Executable file
|
@ -0,0 +1,38 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Ensure the script is run with exactly two arguments
|
||||
if [ $# -ne 2 ]; then
|
||||
echo "Usage: $0 <path> <name>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Define variables
|
||||
path="$1"
|
||||
name="$2"
|
||||
|
||||
# Create the folder structure
|
||||
mkdir -p "$path/$name/_werc" "$path/$name/blog/_werc"
|
||||
|
||||
# Create the first config file (not under blog)
|
||||
cat > "$path/$name/_werc/config" <<EOF
|
||||
extraHeaders='<link rel="stylesheet" type="text/css" href="_werc/style.css">'
|
||||
conf_enable_wiki
|
||||
conf_enable_cssedit $name
|
||||
css_file='_werc/style.css'
|
||||
EOF
|
||||
|
||||
# Create the second config file (under blog)
|
||||
cat > "$path/$name/blog/_werc/config" <<EOF
|
||||
conf_enable_wiki
|
||||
conf_enable_blog
|
||||
conf_blog_only_pull=0
|
||||
conf_blog_editors=$name
|
||||
blogTitle='$name Feed'
|
||||
blogDesc=''
|
||||
EOF
|
||||
|
||||
# Create the style.css file
|
||||
echo "/* Put custom styles here */" > "$path/$name/_werc/style.css"
|
||||
|
||||
# Output a success message
|
||||
echo "Folder structure created successfully at $path/$name"
|
35
scripts/add_web_person.rc
Normal file
35
scripts/add_web_person.rc
Normal file
|
@ -0,0 +1,35 @@
|
|||
#!/bin/rc
|
||||
|
||||
# Check if the correct number of arguments are provided
|
||||
if (~ $#argv 2) {
|
||||
echo "Usage: $0 <path> <name>"
|
||||
exit 1
|
||||
}
|
||||
|
||||
# Assign arguments to variables
|
||||
path = $argv[1]
|
||||
name = $argv[2]
|
||||
|
||||
# Create the folder structure
|
||||
mkdir -p $path/$name/_werc
|
||||
mkdir -p $path/$name/blog/_werc
|
||||
|
||||
# Create the first config file (not under blog)
|
||||
echo "extraHeaders='<link rel=\"stylesheet\" type=\"text/css\" href=\"_werc/style.css\">'" > $path/$name/_werc/config
|
||||
echo "conf_enable_wiki" >> $path/$name/_werc/config
|
||||
echo "conf_enable_cssedit $name" >> $path/$name/_werc/config
|
||||
echo "css_file='_werc/style.css'" >> $path/$name/_werc/config
|
||||
echo "" >> $path/$name/_werc/config
|
||||
|
||||
# Create the second config file (under blog)
|
||||
echo "conf_enable_wiki" > $path/$name/blog/_werc/config
|
||||
echo "conf_enable_blog" >> $path/$name/blog/_werc/config
|
||||
echo "conf_blog_only_pull=0" >> $path/$name/blog/_werc/config
|
||||
echo "conf_blog_editors=$name" >> $path/$name/blog/_werc/config
|
||||
echo "" >> $path/$name/blog/_werc/config
|
||||
|
||||
# Create the style.css file
|
||||
touch $path/$name/_werc/style.css
|
||||
|
||||
# Output a success message
|
||||
echo "Folder structure created successfully at $path/$name"
|
Loading…
Add table
Add a link
Reference in a new issue