Skip to content

Instantly share code, notes, and snippets.

Dmitry Shachnev mitya57

Block or report user

Report or block mitya57

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@mitya57
mitya57 / main.py
Last active Nov 19, 2016
My Oracle Shell
View main.py
# Alternative shell for Oracle database.
# Alpha version, do not use for production purposes.
#
# Author: 2016 Dmitry Shachnev <ich@mitya57.me>
import readline
import shutil
import sys
import cx_Oracle
View cursor.cpp
#include <QtGui/QFont>
#include <QtWidgets/QApplication>
#include <QtWidgets/QTextEdit>
int main(int argc, char **argv) {
QApplication app(argc, argv);
QTextEdit edit;
edit.resize(640, 480);
edit.setHtml(
@mitya57
mitya57 / test_errors.log
Created Jan 25, 2016
Sphinx tests errors with Python 2.7.11
View test_errors.log
======================================================================
FAIL: test_build_html.test_html_output(<etree13.ElementTree.ElementTree object at 0x7f3e05b20110>, 'includes.html', ".//pre/span[@class='s2']", u'\xfc\xf6\xe4')
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/nose/case.py", line 197, in runTest
self.test(*self.arg)
File "/home/dmitry/python-modules/sphinx/tests/test_build_html.py", line 340, in check_xpath
'%r in file %s' % (path, fname))
AssertionError: did not find any node matching xpath ".//pre/span[@class='s2']" in file includes.html
@mitya57
mitya57 / object.hpp
Last active Oct 24, 2015
Описание модели онтологий
View object.hpp
#ifndef ONTXX_OBJECT_HPP
#define ONTXX_OBJECT_HPP
#include <cstdint>
#include <string>
#include <vector>
/** Base objects of the Meta-Ontology [MO].
*
* Root Object
@mitya57
mitya57 / pdfinfo.py
Last active Oct 20, 2015
Statistical information about PDFs
View pdfinfo.py
# Get statistical information about PDFs
# Author: 2015 Dmitry Shachnev <mitya57@gmail.com>
# Required packages (in Debian/Ubuntu):
# - gir1.2-poppler-0.18
# - python3-gi or python-gi
import gi
gi.require_version('Poppler', '0.18')
@mitya57
mitya57 / xsettings.py
Last active May 30, 2017
XSettings implementation in Python 3
View xsettings.py
#!/usr/bin/env python3
# Implementation of XSettings specification in Python 3
# <http://standards.freedesktop.org/xsettings-spec/xsettings-spec-0.5.html>
#
# Copyright (C) 2015 Dmitry Shachnev <mitya57@gmail.com>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
@mitya57
mitya57 / sphinx_log.txt
Created Jul 17, 2015
sympy sphinx build
View sphinx_log.txt
mkdir -p _build/latex _build/doctrees
PYTHONPATH=..: sphinx-build -b latex -d _build/doctrees-latex -D latex_paper_size= src _build/latex
Running Sphinx v1.3.1
loading pickled environment... not yet created
building [mo]: targets for 0 po files that are out of date
building [latex]: all documents
updating environment: 172 added, 0 changed, 0 removed
reading sources... [ 0%] aboutus
reading sources... [ 1%] gotchas
reading sources... [ 1%] guide
@mitya57
mitya57 / log.txt
Created May 29, 2015
sphinxcontrib-programoutput test log
View log.txt
============================= test session starts ==============================
platform linux2 -- Python 2.7.10 -- py-1.4.27 -- pytest-2.7.0
rootdir: /tmp/buildd/sphinxcontrib-programoutput-0.8, inifile:
collected 51 items
tests/test_cache.py .....E
tests/test_command.py ............
tests/test_directive.py EEEEEEEEEEEEEEEEEEEEEE..
tests/test_setup.py E
tests/test_util.py ....
@mitya57
mitya57 / sphinx_test_log
Created Mar 17, 2015
Sphinx testing log
View sphinx_test_log
Checking dependencies...
Temporary files will be placed in /home/dmitry/python-modules/sphinx/Sphinx-1.3/tests/build.
Running Sphinx test suite (with Python 2.7.9)...
test_api_translator.test_html_translator ... ok
test_api_translator.test_html_with_html_translator_class ... ok
test_api_translator.test_html_with_set_translator_for_html_ ... ok
test_api_translator.test_html_with_set_translator_for_html_and_html_translator_class ... ok
test_api_translator.test_html_with_set_translator_for_latex ... ok
test_api_translator.test_html_with_set_translator_for_man ... ok
test_api_translator.test_html_with_set_translator_for_pseudoxml ... ok
@mitya57
mitya57 / scheme.cpp
Created May 19, 2014
thermal-conductivity
View scheme.cpp
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include "struct.h"
void DiagonalMatrix::solve(double *rightCol) {
unsigned s;
for (s = 0; s < size - 1; ++s) {
topDiag[s] /= midDiag[s];
You can’t perform that action at this time.