mirrored 4 minutes ago
0
TimothyxxxFix id 13127de
{
    "id": "5203d847-2572-4150-912a-03f062254390",
    "snapshot": "thunderbird",
    "instruction": "Create a local folder called \"Promotions\" and create a filter to auto move the inbox emails whose subject contains \u201cdiscount\u201d to the new folder",
    "source": "https://support.mozilla.org/en-US/kb/organize-your-messages-using-filters",
    "config": [
        {
            "type": "download",
            "parameters": {
                "files": [
                    {
                        "url": "https://drive.usercontent.google.com/download?id=1EHLRWzBCOsyERkSMUnTF2pnsR0n6ZvtR&export=download&authuser=0&confirm=t&uuid=de09bd5e-bef8-499a-b599-c642af190e10&at=APZUnTXqOsQkxl0zMSX6R1Sgp_v3:1704362491712",
                        "path": "/home/user/thunderbird-profile.tar.gz"
                    }
                ]
            }
        },
        {
            "type": "execute",
            "parameters": {
                "command": [
                    "tar",
                    "-xzv",
                    "--recursive-unlink",
                    "-f",
                    "/home/user/thunderbird-profile.tar.gz",
                    "-C",
                    "/home/user/"
                ]
            }
        },
        {
            "type": "launch",
            "parameters": {
                "command": [
                    "/usr/bin/thunderbird"
                ]
            }
        }
    ],
    "trajectory": "trajectories/",
    "related_apps": [
        "thunderbird"
    ],
    "evaluator": {
        "postconfig": [
            {
                "type": "close_window",
                "parameters": {
                    "window_name": "Message Filters",
                    "strict": true
                }
            },
            {
                "type": "sleep",
                "parameters": {
                    "seconds": 0.5
                }
            }
        ],
        "func": "check_thunderbird_filter",
        "result": {
            "type": "vm_file",
            "path": "/home/user/.thunderbird/t5q2a5hp.default-release/ImapMail/outlook.office365.com/msgFilterRules.dat",
            "dest": "msgFilterRules.dat"
        },
        "expected": {
            "type": "rule",
            "rules": {
                "expect": [
                    {
                        "enabled": "yes",
                        "action": "Move to folder",
                        "actionValue": "mailbox://nobody@Local%20Folders/Promotions",
                        "condition": [
                            "AND (subject,contains,discount)"
                        ]
                    }
                ]
            }
        }
    }
}