Skip to content

Instantly share code, notes, and snippets.

View Alia5's full-sized avatar
🤷‍♂️

Peter Repukat Alia5

🤷‍♂️
View GitHub Profile
@Alia5
Alia5 / replace-classes-in-apk.sh
Created September 21, 2016 03:03 — forked from sebfisch/replace-classes-in-apk.sh
Replaces classes in Android Package Files
#!/bin/bash
# Replaces classes in Android Package Files
# (c) Sebastian Fischer, CC-BY
# Can be used to rebuild an App with a modified version of a used library,
# as required for closed works that link to an LGPL library.
# Depends on: https://code.google.com/p/dex2jar/
public enum ActivateOptions
{
None = 0x00000000, // No flags set
DesignMode = 0x00000001, // The application is being activated for design mode, and thus will not be able to
// to create an immersive window. Window creation must be done by design tools which
// load the necessary components by communicating with a designer-specified service on
// the site chain established on the activation manager. The splash screen normally
// shown when an application is activated will also not appear. Most activations
// will not use this flag.
NoErrorUI = 0x00000002, // Do not show an error dialog if the app fails to activate.
#include <iostream>
#include <Windows.h>
#include <atlbase.h>
#include <Shobjidl.h>
#include <appmodel.h>
#include <AppxPackaging.h>
#include <string>
HRESULT LaunchApplication(LPCWSTR packageFullName, PDWORD pdwProcessId)
{