This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| backtitle="Armbian EMMC backup script, http://www.armbian.com | Author: nopnop2002, Justin42" | |
| title="Backup from EMMC to Image File" | |
| logfile="/tmp/dd.log" | |
| imgdir="/var/images" | |
| sleeptime=1 | |
| debugout="/tmp/debug.log" | |
| emmc_devices=("mmcblk2boot0" "mmcblk2boot1" "mmcblk2") | |
| function DebugEcho() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ( | |
| "Python.Python.3", | |
| "Git.Git", | |
| "GitHub.GitLFS", | |
| "JetBrains.Toolbox", | |
| "JetBrains.PyCharm.Community" | |
| ) | foreach {winget install -e --id $_ -s winget --scope machine} | |
| pause |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Lab 01 - Ex 03.15 - Date2 | |
| // CIS 282 | |
| // Jonathan Lee | |
| public class Date2 | |
| { | |
| private int year; | |
| private int month; | |
| private int day; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public void login(final String username, final String password,final LoginListener loginListener) { | |
| // Logins performed synchronously in its own thread. | |
| Runnable login = new Runnable() { | |
| public void run() { | |
| if(networkHandler.connectTCP()) { | |
| IoSession session = networkHandler.getSession(); | |
| ClientData clientData = networkHandler.getClientData(); | |
| // Block this thread while waiting for reply | |
| session.getConfig().setUseReadOperation(true); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public boolean connectTCP() { | |
| ConnectFuture future = connector.connect(new InetSocketAddress(serverHost, serverPort)); | |
| future.awaitUninterruptibly(); | |
| if(future.isConnected()) { | |
| session = future.getSession(); | |
| return true; | |
| } | |
| else { | |
| return false; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Justin: | |
| - ==: org.bukkit.inventory.ItemStack | |
| type: FIRE | |
| amount: 5 | |
| - ==: org.bukkit.inventory.ItemStack | |
| type: FIRE | |
| amount: 5 | |
| - ==: org.bukkit.inventory.ItemStack | |
| type: FIRE | |
| amount: 5 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| for(ItemStack itemStack : itemStash.collect(player)) { | |
| player.sendMessage("Giving " + itemStack.getAmount()); | |
| remainingItems.addAll(player.getInventory().addItem(itemStack).values()); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public ArrayList<ItemStack> collect(Player player) { | |
| ArrayList<ItemStack> stackList = new ArrayList<ItemStack>(); | |
| if(hasItems(player)) { | |
| try { | |
| stackList = (ArrayList<ItemStack>) config.get(player.getName()); | |
| config.set(player.getName(), null); | |
| save(); | |
| } | |
| catch (ClassCastException ex) { | |
| corruptionWarning(player); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 08:50:02 [SEVERE] Could not pass event AuctionEvent to Salesmania | |
| org.bukkit.event.EventException | |
| at org.bukkit.plugin.java.JavaPluginLoader$1.execute(JavaPluginLoader.java:304) | |
| at org.bukkit.plugin.RegisteredListener.callEvent(RegisteredListener.java:62) | |
| at org.bukkit.plugin.SimplePluginManager.callEvent(SimplePluginManager.java:460) | |
| at net.invisioncraft.plugins.salesmania.Auction.start(Auction.java:160) | |
| at net.invisioncraft.plugins.salesmania.commands.auction.AuctionStart.execute(AuctionStart.java:108) | |
| at net.invisioncraft.plugins.salesmania.commands.auction.AuctionCommandExecutor.onCommand(AuctionComma | |
| ndExecutor.java:89) | |
| at org.bukkit.command.PluginCommand.execute(PluginCommand.java:40) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public List<String> infoReplace(List<String> infoList) { | |
| List<String> newInfoList = new ArrayList<String>(); | |
| Iterator<String> infoIterator = infoList.iterator(); | |
| while(infoIterator.hasNext()) { | |
| String info = infoIterator.next(); | |
| if(info == "%enchantinfo%" && itemStack.getEnchantments().isEmpty()) { | |
| continue; | |
| } | |
| info = info.replace("%owner%", owner.getName()); |
NewerOlder