Visual Studio Code的一些插件
- Material Icon Theme:文件图标主题
- Error Lens:语法错误提示
- Live Server:简易HTTP服务器
配置好环境变量后,执行
npm rebuild
//开启定时任务
@EnableScheduling
//开启异步调用方法
@EnableAsync
public class SpringBootStarterApplication {
public static void main(String[] args) {
SpringApplication.run(SpringBootStarterApplication.class, args);
}
}
@Component
public class TestTask {
private static final SimpleDateFormat dateFormat = new SimpleDateFormat("HH:mm:ss");
//定义每过3秒执行任务
@Scheduled(fixedRate = 3000)
//@Scheduled(cron = "4-40 * * * * ?")
public void reportCurrentTime() {
System.out.println("现在时间:" + dateFormat.format(new Date()));
}
}
将img文件(2022101-Ipv4-Bypass-5.15-x86-64-generic-squashfs-combined-efi.img)解压出来,使用VBoxManage.exe进行转换,cmd语句如下:
D:\vbox\openwrt>"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" convertfromraw -format VDI 2022101-Ipv4-Bypass-5.15-x86-64-generic-squashfs-combined-efi.img 2022101-Ipv4-Bypass-5.15-x86-64-generic-squashfs-combined-efi.vdi
新建虚拟机使用转换出来的vdi虚拟硬盘文件,首次启动前先扩大虚拟磁盘空间,否则磁盘空间满,配置文件修改后重启会恢复默认值。
参考微软文章
Hyper-V integration components update for Windows virtual machines (microsoft.com)
dism /online /Add-Package /PackagePath:C:\Users\neo\Desktop\windows6.x-hypervintegrationservices-x64.cab