Unified · Split
| @@ -1139,16 +1139,8 @@ local function get_clipboard(clip) · 1138 unmodified lines | ||
| 1139 | 1139 | if not res.error then |
| 1140 | 1140 | return res.stdout |
| 1141 | 1141 | end |
| 1142 | − elseif platform == 'windows' then | |
| 1142 | + elseif platform == 'windows' or platform == 'darwin' then | |
| 1143 | 1143 | return mp.get_property('clipboard/text', '') |
| 1144 | − elseif platform == 'darwin' then | |
| 1145 | − local res = utils.subprocess({ | |
| 1146 | − args = { 'pbpaste' }, | |
| 1147 | − playback_only = false, | |
| 1148 | − }) | |
| 1149 | − if not res.error then | |
| 1150 | − return res.stdout | |
| 1151 | − end | |
| 1152 | 1144 | end |
| 1153 | 1145 | return '' |
| 1154 | 1146 | end |