Use the Link create() method to create a symlink.
import 'dart:io'; main() async { // Get the system temp directory. var temp = await Directory.systemTemp.createTemp('my_temp_dir'); // Generate a couple of paths. var first = '${temp.path}${Platform.pathSeparator}first'; var second = '${temp.path}${Platform.pathSeparator}second'; // Create a symlink. Link symLink = await new Link(second).create(first); print(symLink); }
声明:本文来自网络,不代表【好得很程序员自学网】立场,转载请注明出处:http://www.haodehen.cn/did129491