Skip to content

Commit

Permalink
Don't crash if .bashrc doesn't exist (closes #39) (#40)
Browse files Browse the repository at this point in the history
  • Loading branch information
christophetd authored Dec 6, 2024
1 parent 3df93f7 commit e341f2b
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ To check whether the installation succeeded, run the following command and verif

```bash
$ scfw --version
1.0.1
1.0.2
```

### Post-installation steps
Expand Down
2 changes: 1 addition & 1 deletion scfw/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
A supply-chain "firewall" for preventing the installation of vulnerable or malicious `pip` and `npm` packages.
"""

__version__ = "1.0.1"
__version__ = "1.0.2"
3 changes: 2 additions & 1 deletion scfw/configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@ def run_configure(args: Namespace) -> int:

answers = inquirer.prompt(_get_questions())
for file in [Path.home() / file for file in _CONFIG_FILES]:
_update_config_file(file, _format_answers(answers))
if file.exists():
_update_config_file(file, _format_answers(answers))

print(_EPILOGUE)

Expand Down
2 changes: 1 addition & 1 deletion tests/commands/test_pip_command.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def test_pip_command_would_install_exact():
("docutils", "0.15.2"),
("jmespath", "0.10.0"),
("python-dateutil", "2.9.0.post0"),
("six", "1.16.0"),
("six", "1.17.0"),
("urllib3", "1.25.11")
]
)
Expand Down

0 comments on commit e341f2b

Please sign in to comment.