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
| /* | |
| * AsyncTaskCodeActivity | |
| * | |
| * Copyright (c) LuzFaltex, LLC. | |
| * All rights reserved. | |
| * | |
| * MIT License | |
| * | |
| * Permission is hereby granted, free of charge, to any person obtaining a copy of this | |
| * software and associated documentation files (the "Software"), to deal in the Software |
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
| Function New-DotNetToast { | |
| [cmdletBinding()] | |
| Param( | |
| [Parameter(Mandatory, Position = 0)] | |
| [String] | |
| $Title, | |
| [Parameter(Mandatory,Position = 1)] | |
| [String] | |
| $Message, |
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
| #!/usr/bin/python | |
| import csv, json, sys, re, os | |
| import glob | |
| try: | |
| loglevel = int(os.environ["LOGLEVEL"]) | |
| except: | |
| loglevel = 1 |
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
| # An overly complicated SIP config checker | |
| # This is a technically interesting implementation because it does not rely on csrutil | |
| # Instead it queries the kernel directly for the current configuration status | |
| # This means, for example, in environments where SIP has been disabled and csrutil has | |
| # been removed or modified (say, with DYLD_LIBRARY_PATH), as long as python can run you | |
| # can still check status | |
| # Additionally, checking the nvram csr-active-config setting isn't accurate now with | |
| # 10.12.2+, since running "sudo csrutil clear" deletes the variable until reboot, |
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
| // Based on Chris Webb's blog post - http://blog.crossjoin.co.uk/2014/05/21/expanding-all-columns-in-a-table-in-power-query/ | |
| let | |
| //Define function taking two parameters - a table and an optional column number | |
| Source = (TableToExpand as table, optional ColumnNumber as number) => | |
| let | |
| //If the column number is missing, make it 0 | |
| ActualColumnNumber = if (ColumnNumber=null) then 0 else ColumnNumber, | |
| //Find the column name relating to the column number | |
| ColumnName = Table.ColumnNames(TableToExpand){ActualColumnNumber}, |
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
| <?php | |
| header('Content-Type: text/csv; charset=utf-8'); | |
| header('Content-Disposition: attachment;filename="export.csv"'); | |
| header('Cache-Control: max-age=0'); | |
| // See: http://es2.php.net/manual/en/wrappers.php.php | |
| $fpcsv = fopen('php://output', "a+"); | |
| // Put your SQL query here | |
| $exportcsv_q = mysql_query($query); | |
| if (@mysql_num_rows($exportcsv_q) > 0) { | |
| $campos = mysql_num_fields($exportcsv_q); |