mirror of
https://github.com/rendercv/rendercv.git
synced 2026-10-23 04:44:41 -04:00
docs: update
This commit is contained in:
1 parent
031687f5ab
commit
75169637c3
19 files changed
+329
-306
No files matched your search
@@ -0,0 +1,18 @@
|
||||
|
||||
# Frequently Asked Questions (FAQ)
|
||||
|
||||
## How can I add a new social network to RenderCV?
|
||||
|
||||
To add a new social network to RenderCV, go to the `rendercv/data_models.py` file and follow these steps:
|
||||
|
||||
1. Append the social network name (for example, "Facebook") to the `SocialNetworkName` type.
|
||||
2. If necessary, implement its username validation in the `SocialNetwork.check_username` method.
|
||||
3. Implement its URL generation using the `SocialNetwork.url` method. If the URL can be generated by appending the username to a hostname, only update `url_dictionary`.
|
||||
4. Finally, include the $\LaTeX$ icon of the social network to the `icon_dictionary` in the `CurriculumVitae.connections` method. RenderCV uses the [`fontawesome5`](https://ctan.org/pkg/fontawesome5?lang=en) package. The available icons can be seen [here](https://fosszone.csd.auth.gr/CTAN/fonts/fontawesome5/doc/fontawesome5.pdf).
|
||||
|
||||
Then, the tests should be implemented for the new social network with the following steps:
|
||||
|
||||
1. Go to `tests/test_data_models.py` and update `test_social_network_url` accordingly, i.e., add a new `(network, username, expected_url)` tuple to the `pytest.mark.parametrize` decorator.
|
||||
2. Go to `tests/conftest.py` and add the new social network to `rendercv_filled_curriculum_vitae_data_model`.
|
||||
3. Set `update_testdata` to `True` in `conftest.py` and run the tests to update the `testdata` folder.
|
||||
4. Review the updated `testdata` folder manually to ensure everything works as expected. Then, set `update_testdata` to `False` and push the changes.
|
||||
Reference in new issue
Block a user