Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

fix: incorrect json wallpaper path #564

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions pywal/export.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import re

from . import util
from .settings import CACHE_DIR, CONF_DIR, MODULE_DIR
from .settings import CACHE_DIR, CONF_DIR, MODULE_DIR, OS


def template(colors, input_file, output_file=None):
Expand Down Expand Up @@ -77,7 +77,12 @@ def template(colors, input_file, output_file=None):
def flatten_colors(colors):
"""Prepare colors to be exported.
Flatten dicts and convert colors to util.Color()"""
all_colors = {"wallpaper": colors["wallpaper"],
wallpaper_path = colors["wallpaper"]

if OS == "Windows":
wallpaper_path = wallpaper_path.replace("\\", "\\\\")

all_colors = {"wallpaper": wallpaper_path,
"alpha": colors["alpha"],
**colors["special"],
**colors["colors"]}
Expand Down