Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
jcferrei committed Nov 29, 2023
1 parent 17a20f0 commit 03cca47
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 50 deletions.
55 changes: 8 additions & 47 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,65 +5,33 @@ First, you need to have the repository in your computer:
You can use the http version or the ssh version.
```
SSH
git@gitlab.epfl.ch:ipese/blog/ipese-blog-v2.git
git@github.com:IPESE/climact-blog.git
```

```
http method
git clone https://gitlab.epfl.ch/ipese/blog/ipese-blog-v2.git
git clone https://github.com/IPESE/climact-blog.git
cd ipese-blog-v2
```
**To run localy you have 2 options:**
If you have docker installed in your computer this is the easiest way to build it.
If you are developping for the project, it will take longer to setup your environment but the rebuild will be faster after every change.
#### Install with docker
2. Make sure you have Docker installed and running
3. Run the container
```sh
docker compose up -d --build --force-recreate
```
4. Access the blog at [localhost:8080](localhost:8080)

#### Setup local environment
2. make sure you have the following installed:
2. Make sure you have the following installed:
* quarto
* R
* python (you might also need to run `pip install beautifulsoup4 pandas`)
* GDAL
3. move to the quarto blog folder
```
cd ipese-blog
```
4. run the following to preview the website:
3. Run the following to preview the website:
```
quarto preview
```
the first run will install all the R packages necessary and will take a while but everytime you rebuild, the process will be faster
# Deploy
- To deploy to production, simply commit your changes to the main branch with a tag
- To achieve this you can use your git client software. If your not familiar with git, heres a quick tutorial with the command line:

1. Mske sure your are in the main branch with ```git branch``` if you're not, move to it wit ```git checkout main```
2. Add your changes to the commit (the "." makes sure you add every file, you can replace it with the path to a folder or file)
```
git add .
```
3. Commit your changes (the string should be a small text explaining your changes)
```
git commit -m "your message"
```
4. add a tag (your tag name should represent the changes ex: **bibdatamanagement2-v2.0.0**)
```
git tag your-tag-name
```
5. push the changes with tags
```
git push origin main --tags
```
- To deploy to production, simply commit your changes to the main branch
- Make sure you only commit to the main branch if your code works
- If you want to save your work in progress in github, feel free to create a branch with your name
# Other information
### Add edit button
### Add edit and pdf button to your post
to add an edit button to a post you can import editButton.js
```
<script src="../../resources/scripts/editButton.js"></script>
Expand All @@ -76,10 +44,3 @@ to add an edit button to a post you can import editButton.js
### Write a post
For instructions on how to write a post go to the IT Tutorials menu and there is a post dedicated to creating new posts
Refer to the _template folder to create posts inside the different menus
# TODO
- ❌ integrate AMPL to the build process
- ❌ Correct functions for ipese-blog/energy_systems/2022-12-15-on-the-role-of-hydrogen-for-the-energy-transition/index.qmd
- ❌ Upload Reho to pypi
- ❌ Correct REHO integration in ipese-blog/urban_systems/2023-02-28-gravelone-energy-scenarios/index.qmd
- ❌ Correct ipese-blog/it_tutorials/2022-07-01-svg-and-bibdatamanagement/index.qmd.err
4 changes: 2 additions & 2 deletions _quarto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ project:
- ./resources/scripts/getCategories.py

website:
favicon: "resources/images/favicon.png"
favicon: "resources/images/favicon.ico"
navbar:
logo: "resources/images/logo.png"
logo: "resources/images/logo.webp"
left:
- index.qmd
- about.qmd
Expand Down
Binary file added resources/images/favicon.ico
Binary file not shown.
Binary file removed resources/images/favicon.png
Binary file not shown.
Binary file removed resources/images/logo.png
Binary file not shown.
Binary file added resources/images/logo.webp
Binary file not shown.
1 change: 1 addition & 0 deletions resources/scripts/sada.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion styles.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* css styles */
.navbar-logo{
max-height:50px
max-height:25px
}
.quarto-title-banner,
.quarto-title,
Expand Down

0 comments on commit 03cca47

Please sign in to comment.