Skip to content

Instantly share code, notes, and snippets.

View mloskot's full-sized avatar
🏠
Working from home

Mateusz Łoskot mloskot

🏠
Working from home
View GitHub Profile
@mloskot
mloskot / mage-run-swdt-with-custom-boxes.log
Last active April 27, 2023 10:09
master-nowsl: initial run with mage and custom updated vagrant boxes
$ mage | tee mage.log
Running dependency: Fetch
Running dependency: startup
2023/04/27 06:56:05 main.go:71: [swdt] Setting environment variable VAGRANT_VARIABLES=variables.local.yaml
2023/04/27 06:56:05 fetch.go:35: [swdt] Downloading manifest https://storage.googleapis.com/k8s-release-dev/ci/latest-1.27.txt
Running dependency: Run
2023/04/27 06:56:06 fetch.go:41: [swdt] Downloading binaries of Kubernetes v1.27.1-13+6494bc61297cd0
Running dependency: checkVagrant
2023/04/27 06:56:06 fetch.go:50: [swdt] Downloading sync\linux\bin\kubeadm from https://storage.googleapis.com/k8s-release-dev/ci/v1.27.1-13+6494bc61297cd0/bin/linux/amd64/kubeadm
2023/04/27 06:56:06 fetch.go:55: [swdt] File exists. Skipping.
---
name: 'upgrade-cluster-flux'
on:
schedule:
# Every Monday at 3 AM UTC
- cron: "0 3 * * 1"
workflow_dispatch:
inputs:
environment:
@mloskot
mloskot / boost-gil-changelog-develop-vs-master-for-boost-1_80.md
Last active May 12, 2022 07:51
Boost.GIL changes that will be merged from current develop into master for release with Boost 1.80

Discussion:

git log origin/master..origin/develop --pretty=format:"1. [%h](http://github.com/boostorg/gil/commit/%H) - %s"

| # | Date | Hash | Subject |

@mloskot
mloskot / soci-4.0.0-github-changelog.md
Last active March 23, 2022 18:39
Changes in SOCI 4.0.0 since 3.2.3

Changes in SOCI 4.0.0 since 3.2.3 using git log 3.2.3..master --pretty=format:"1. [%h](http://github.com/soci/soci/commit/%H) - %s"

  1. f8f97fb - Disable use of std::ptr_fun when compiling as C++17 (#751)
  2. 04e1870 - Fix crash in Windows by correctly initializing session member in copy constructor (#739)
  3. 9d0caa1 - Use 64-bit integer for next sequence and last insert ID values (#720)
  4. 349ce86 - Refine try-catch scopes in failover for PostgreSQL (#733)
  5. a47fd69 - Add pg reconnection loop (#731)
  6. 64e917c - Add finished call in pg failo
@mloskot
mloskot / boost_property_tree_json_array.cpp
Created December 22, 2011 11:11
Simple example of parsing and consuming JSON array with boost::property_tree
#ifdef _MSC_VER
#include <boost/config/compiler/visualc.hpp>
#endif
#include <boost/property_tree/ptree.hpp>
#include <boost/property_tree/json_parser.hpp>
#include <boost/foreach.hpp>
#include <cassert>
#include <exception>
#include <iostream>
#include <sstream>
@mloskot
mloskot / boost_gil_issue_with_interleaved_ptr.cpp
Created October 10, 2012 15:06
How to use Boost.GIL views attached to bytes array with interleaved_ptr, versus view constructed with cast to pixel type
//////////////////////////////////////////////////////////////////////////////////////////////////////
// Problem reported to Boost mailing list: http://thread.gmane.org/gmane.comp.lib.boost.devel/234991
//
// How to use Boost.GIL views attached to bytes array with interleaved_ptr,
// versus view constructed with cast to pixel type
//////////////////////////////////////////////////////////////////////////////////////////////////////
std::size_t w = 512;
std::size_t h = 256;
std::size_t sizeRow = 1536; // calculated for Windows DIB
std::size_t sizeImage = sizeRow * h;
@mloskot
mloskot / archlinux-install-notes.md
Last active July 28, 2021 12:16
My notes on Arch Linux installation
@mloskot
mloskot / lectures_watching_tracklog.md
Last active November 3, 2020 09:17
Watched Lectures Log (programming, mathematics, algorithms, databases, etc.)
@mloskot
mloskot / test_sqlserver_cast_bit_bug_report.cpp
Created April 15, 2020 19:57
Conversion with CAST(? AS BIT) only works for 0 or 1 when using ODBC API. 22003: [Microsoft][ODBC Driver 17 for SQL Server]Numeric value out of rang
// MWE for bug report submitted to SQL Server:
// https://feedback.azure.com/forums/908035-sql-server/suggestions/40180918-conversion-with-cast-as-bit-only-works-for-0-or
#include <cassert>
#include <cstdint>
#include <iostream>
#include <string>
#include <vector>
#define NOMINMAX
#include <windows.h>
#include <sql.h>
@mloskot
mloskot / incredibuild-non-benchmark.md
Last active November 26, 2019 13:41
IncrediBuild non-Benchmark

Running BuildConsole.exe of IncrediBuild 9.4 to build a large project using Visual Studio 2017:

  • Machine 1: Intel Xeon E-2670v3 with 24 physical cores
  • Machine 2: Intel Xeon Gold 6230 with 40 physical cores
  • RAM 64 GB on both
  • HDD: SSD on both

The source code tree git clean-ed, IncrediBuild history and cache cleaned and machine restarted before every build.

  1. Machine 1 with IB on 16 cores of 48 logical cores (Hyper-Threading enabled)