Skip to content

Commit

Permalink
fix(shader): resolve relative path
Browse files Browse the repository at this point in the history
  • Loading branch information
loqusion committed Dec 14, 2023
1 parent d2d7303 commit 0c45781
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/hyprshade/shader/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ class Shader:

def __init__(self, shader_name_or_path: str):
self._given_path = (
shader_name_or_path if shader_name_or_path.find(path.sep) != -1 else None
path.abspath(shader_name_or_path)
if shader_name_or_path.find(path.sep) != -1
else None
)
self._name = _stripped_basename(shader_name_or_path)
self._stale = self._given_path is not None and not path.exists(self._given_path)
Expand Down

0 comments on commit 0c45781

Please sign in to comment.