text:
// File: vogl_context_info.h
#ifndef VOGL_CONTEXT_INFO_H
#define VOGL_CONTEXT_INFO_H

#include "vogl_common.h"
#include "vogl_dynamic_string.h"

#include "vogl_json.h"

enum vogl_gl_version_t
{
    VOGL_GL_VERSION_UNKNOWN = 0x000000,
    VOGL_GL_VERSION_1_0 = 0x010000,
    VOGL_GL_VERSION_1_1 = 0x010100,
    VOGL_GL_VERSION_1_2 = 0x010200,
    VOGL_GL_VERSION_1_2_1 = 0x010201,
    VOGL_GL_VERSION_1_3 = 0x010300,
    VOGL_GL_VERSION_1_4 = 0x010400,
    VOGL_GL_VERSION_1_5 = 0x010500,
    VOGL_GL_VERSION_2_0 = 0x020000,
    VOGL_GL_VERSION_2_1 = 0x020100,
    VOGL_GL_VERSION_3_0 = 0x030000,
    VOGL_GL_VERSION_3_1 = 0x030100,
    VOGL_GL_VERSION_3_2 = 0x030200,
    VOGL_GL_VERSION_3_3 = 0x030300,
    VOGL_GL_VERSION_4_0 = 0x040000,
    VOGL_GL_VERSION_4_1 = 0x040100,
    VOGL_GL_VERSION_4_2 = 0x040200,
    VOGL_GL_VERSION_4_3 = 0x040300,
    VOGL_GL_VERSION_4_4 = 0x040400,
    VOGL_GL_VERSION_4_5 = 0x040500,
    VOGL_GL_VERSION_4_6 = 0x040600,
    VOGL_GL_VERSION_4_7 = 0x040700,
    VOGL_GL_VERSION_4_8 = 0x040800,
    VOGL_GL_VERSION_4_9 = 0x040900,
    VOGL_GL_VERSION_5_0 = 0x050000,
    VOGL_GL_VERSION_5_1 = 0x050100,
    VOGL_GL_VERSION_5_2 = 0x050200,
    VOGL_GL_VERSION_5_3 = 0x050300,
    VOGL_GL_VERSION_5_4 = 0x050400,
    VOGL_GL_VERSION_5_5 = 0x050500
};

#define VOGL_CREATE_GL_VERSION(major, minor, patch) static_cast<vogl_gl_version_t>(((major) << 16) | ((minor) << 8) | (patch))

#define VOGL_GL_VERSION_GET_MAJOR(x) (((x) >> 16) & 0xFF)
#define VOGL_GL_VERSION_GET_MINOR(x) (((x) >> 8) & 0xFF)
#define VOGL_GL_VERSION_GET_PATCH(x) ((x) & 0xFF)

int vogl_determine_attrib_list_array_size(const int *attrib_list);

class vogl_context_attribs
{
public:
    typedef vogl::vector<int> attrib_vec;

    vogl_context_attribs();
    vogl_context_attribs(const int *pAttribs);
    vogl_context_attribs(const int *pAttribs, uint num_attribs);
    vogl_context_attribs(const attrib_vec &vec);

    void init(const int *pAttribs);
    void init(const int *pAttribs, uint num_attribs);
    void init(const attrib_vec &vec);

    void clear()
    {
        m_attribs.clear();
    }

    bool serialize(vogl::json_node &node) const;
    bool deserialize(const vogl::json_node &node);

    const attrib_vec &get_vec() const
    {
        return m_attribs;
    }
    attrib_vec &get_vec()
    {
        return m_attribs;
    }

    int *get_ptr()
    {
        return m_attribs.get_ptr();
    }
    const int *get_ptr() const
    {
        return m_attribs.get_ptr();
    }

    uint size() const
    {
        return m_attribs.size();
    }
    int operator[](uint i) const
    {
        return m_attribs[i];
    }
    int &operator[](uint i)
    {
        return m_attribs[i];
    }

    // Returns offset of value following key, or -1 if not found (or if the key was found but it was at the very end of the int array).
    int find_value_ofs(int key_to_find) const;
    bool has_key(int key_to_find) const
    {
        return find_value_ofs(key_to_find) >= 0;
    }
    bool get_value(int key_to_find, int &val) const;
    int get_value_or_default(int key_to_find, int def = 0) const
    {
        int val = 0;
        if (!get_value(key_to_find, val))
            return def;
        return val;
    }
    void add_key(int key, int value);

    bool check() const;

private:
    attrib_vec m_attribs;
};

// TODO: Add replay context handle
class vogl_context_desc
{
public:
    vogl_context_desc()
    {
        VOGL_FUNC_TRACER

        clear();
    }

    vogl_context_desc(gl_entrypoint_id_t creation_func, GLboolean direct, vogl_trace_ptr_value trace_context, vogl_trace_ptr_value trace_share_context, const vogl_context_attribs &attribs)
    {
        VOGL_FUNC_TRACER

        clear();

        init(creation_func, direct, trace_context, trace_share_context, attribs);
    }

    void init(gl_entrypoint_id_t creation_func, GLboolean direct, vogl_trace_ptr_value trace_context, vogl_trace_ptr_value trace_share_context, const vogl_context_attribs &attribs)
    {
        VOGL_FUNC_TRACER

        m_creation_func = creation_func;
        m_direct = direct;
        m_trace_context = trace_context;
        m_trace_share_context = trace_share_context;
        m_attribs = attribs;
    }

    void clear()
    {
        VOGL_FUNC_TRACER

        m_creation_func = VOGL_ENTRYPOINT_INVALID;
        m_direct = false;
        m_trace_context = 0;
        m_trace_share_context = 0;
        m_attribs.clear();
    }

    bool serialize(json_node &node, const vogl_blob_manager &blob_manager) const
    {
        VOGL_FUNC_TRACER

        VOGL_NOTE_UNUSED(blob_manager);

        node.add_key_value("creation_func", (m_creation_func != VOGL_ENTRYPOINT_INVALID) ? g_vogl_entrypoint_descs[m_creation_func].m_pName : "");
        node.add_key_value("direct", m_direct);
        node.add_key_value("trace_context", static_cast<uint64_t>(m_trace_context));
        node.add_key_value("trace_share_handle", static_cast<uint64_t>(m_trace_share_context));

        return m_attribs.serialize(node);
    }

    bool deserialize(const json_node &node, const vogl_blob_manager &blob_manager)
    {
        VOGL_FUNC_TRACER

        VOGL_NOTE_UNUSED(blob_manager);

        m_creation_func = vogl_find_entrypoint(node.value_as_string("creation_func"));
        m_direct = node.value_as_bool("direct");
        m_trace_context = static_cast<vogl_trace_ptr_value>(node.value_as_uint64("trace_context"));
        m_trace_share_context = static_cast<vogl_trace_ptr_value>(node.value_as_uint64("trace_share_handle"));

        return m_attribs.deserialize(node);
    }

    gl_entrypoint_id_t get_creation_func() const
    {
        return m_creation_func;
    }
    GLboolean get_direct() const
    {
        return m_direct;
    }
    vogl_trace_ptr_value get_trace_context() const
    {
        return m_trace_context;
    }
    vogl_trace_ptr_value get_trace_share_context() const
    {
        return m_trace_share_context;
    }

    const vogl_context_attribs &get_attribs() const
    {
        return m_attribs;
    }
    vogl_context_attribs &get_attribs()
    {
        return m_attribs;
    }

private:
    gl_entrypoint_id_t m_creation_func;
    GLboolean m_direct;
    vogl_trace_ptr_value m_trace_context;
    vogl_trace_ptr_value m_trace_share_context;

    vogl_context_attribs m_attribs;
};

class vogl_context_info
{
public:
    vogl_context_info();

    // Inits from the current GL context
    vogl_context_info(const vogl_context_desc &desc);

    // Inits from the current GL context
    bool init(const vogl_context_desc &desc);

    void clear();

    inline bool is_valid() const
    {
        return m_is_valid;
    }

    bool serialize(vogl::json_node &node, const vogl_blob_manager &blob_manager) const;
    bool deserialize(const vogl::json_node &node, const vogl_blob_manager &blob_manager);

    const vogl_context_desc &get_desc() const
    {
        return m_desc;
    }

    inline vogl_gl_version_t get_version() const
    {
        return m_version;
    }
    inline vogl_gl_version_t get_glsl_version() const
    {
        return m_glsl_version;
    }

    inline bool is_forward_compatible() const
    {
        return m_forward_compatible;
    }
    inline bool is_core_profile() const
    {
        return m_core_profile;
    }
    inline bool is_compatibility_profile() const
    {
        return !m_core_profile;
    }
    inline bool is_debug_context() const
    {
        return m_debug_context;
    }

    inline const vogl::dynamic_string &get_vendor_str() const
    {
        return m_vendor_str;
    }
    inline const vogl::dynamic_string &get_renderer_str() const
    {
        return m_renderer_str;
    }
    inline const vogl::dynamic_string &get_version_str() const
    {
        return m_version_str;
    }
    inline const vogl::dynamic_string &get_glsl_version_str() const
    {
        return m_glsl_version_str;
    }

    inline const vogl::dynamic_string_array &get_extensions() const
    {
        return m_extensions;
    }

    // Not case sensitive. Currently uses a binary search of strings, so it's not terribly slow but it's not super fast either.
    bool supports_extension(const char *pExt) const;

    uint get_max_vertex_attribs() const
    {
        return m_max_vertex_attribs;
    }

    // compat only - will be 0 in core
    uint get_max_texture_coords() const
    {
        return m_max_texture_coords;
    }
    // compat only - will be 0 in core
    uint get_max_texture_units() const
    {
        return m_max_texture_units;
    }
    uint get_max_texture_image_units() const
    {
        return m_max_texture_image_units;
    }
    uint get_max_combined_texture_coords() const
    {
        return m_max_combined_texture_coords;
    }
    uint get_max_draw_buffers() const
    {
        return m_max_draw_buffers;
    }
    uint get_max_lights() const
    {
        return m_max_lights;
    }
    uint get_max_uniform_buffer_bindings() const
    {
        return m_max_uniform_buffer_bindings;
    }
    uint get_max_arb_program_matrices() const
    {
        return m_max_arb_program_matrices;
    }
    uint get_max_arb_vertex_program_env_params() const
    {
        return m_max_arb_vertex_program_env_params;
    }
    uint get_max_arb_fragment_program_env_params() const
    {
        return m_max_arb_fragment_program_env_params;
    }
    uint get_max_transform_feedback_separate_attribs() const
    {
        return m_max_transform_feedback_separate_attribs;
    }

private:
    vogl_context_desc m_desc;

    vogl_gl_version_t m_version;
    vogl_gl_version_t m_glsl_version;

    bool m_forward_compatible;
    bool m_core_profile;
    bool m_debug_context;

    vogl::dynamic_string m_version_str;
    vogl::dynamic_string m_glsl_version_str;
    vogl::dynamic_string m_vendor_str;
    vogl::dynamic_string m_renderer_str;

    // Sorted driver reported extensions.
    vogl::dynamic_string_array m_extensions;
    // "Core" extensions are those extensions we know this context must support, independent of whether or not it actually appears in extensions.
    vogl::dynamic_string_array m_core_extensions;

    uint m_max_vertex_attribs;
    uint m_max_texture_coords;
    uint m_max_texture_units;
    uint m_max_texture_image_units;
    uint m_max_combined_texture_coords;
    uint m_max_draw_buffers;
    uint m_max_lights;
    uint m_max_uniform_buffer_bindings;
    uint m_max_arb_program_matrices;
    uint m_max_arb_vertex_program_env_params;
    uint m_max_arb_fragment_program_env_params;
    uint m_max_transform_feedback_separate_attribs;

    bool m_is_valid;

    void query_string(vogl::dynamic_string &str, GLenum name);
    vogl_gl_version_t parse_version_string(const vogl::dynamic_string &str);
    bool query_extensions();
    void init_context_limits();
    void determine_core_extensions();
};

#endif // VOGL_CONTEXT_INFO_H


text:
package com.github.pfichtner.jrunalyser.base.data;

import java.io.Serializable;
import java.util.concurrent.TimeUnit;

import com.google.common.math.LongMath;
import com.google.common.primitives.Doubles;

public class DefaultSpeed implements Speed, Serializable {

	private static final long serialVersionUID = 1609904844575774284L;

	private static final long fix = TimeUnit.MILLISECONDS.convert(1,
			TimeUnit.DAYS);

	private final double dPerT;
	private final DistanceUnit distanceUnit;
	private final TimeUnit timeUnit;

	public DefaultSpeed(Distance distance, Duration duration) {
		this(distance.getValue(distance.getDistanceUnit())
				/ duration.getValue(duration.getTimeUnit()), distance
				.getDistanceUnit(), duration.getTimeUnit());
	}

	public DefaultSpeed(double dPerT, DistanceUnit distanceUnit,
			TimeUnit timeUnit) {
		this.dPerT = dPerT;
		this.distanceUnit = distanceUnit;
		this.timeUnit = timeUnit;
	}

	public DefaultSpeed convert(DistanceUnit distanceUnit, TimeUnit timeUnit) {
		return convert(distanceUnit, 1, timeUnit);
	}

	private DefaultSpeed convert(DistanceUnit distanceUnit, int time,
			TimeUnit timeUnit) {
		if (distanceUnit == this.distanceUnit && timeUnit == this.timeUnit) {
			return this;
		}
		long longTime = LongMath.checkedMultiply(time, fix);
		return new DefaultSpeed(distanceUnit.convert(
				this.dPerT * this.timeUnit.convert(longTime, timeUnit),
				this.distanceUnit) / fix, distanceUnit, timeUnit);
	}

	@Override
	public Pace toPace(TimeUnit timeUnit, DistanceUnit distanceUnit) {
		return new DefaultPace(1 / getValue(distanceUnit, timeUnit), timeUnit,
				distanceUnit);
	}

	@Override
	public DistanceUnit getDistanceUnit() {
		return this.distanceUnit;
	}

	@Override
	public TimeUnit getTimeUnit() {
		return this.timeUnit;
	}

	@Override
	public double getValue(DistanceUnit distanceUnit, TimeUnit timeUnit) {
		return convert(distanceUnit, timeUnit).dPerT;
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		long temp;
		temp = Double.doubleToLongBits(this.dPerT);
		result = prime * result + (int) (temp ^ (temp >>> 32));
		result = prime
				* result
				+ ((this.distanceUnit == null) ? 0 : this.distanceUnit
						.hashCode());
		result = prime * result
				+ ((this.timeUnit == null) ? 0 : this.timeUnit.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		DefaultSpeed other = (DefaultSpeed) obj;
		if (Double.doubleToLongBits(this.dPerT) != Double
				.doubleToLongBits(other.dPerT))
			return false;
		if (this.distanceUnit != other.distanceUnit)
			return false;
		if (this.timeUnit != other.timeUnit)
			return false;
		return true;
	}

	@Override
	public String toString() {
		return this.dPerT + " " + this.distanceUnit + " per " + this.timeUnit;
	}

	public int compareTo(Speed o) {
		return Doubles.compare(getValue(this.distanceUnit, this.timeUnit),
				o.getValue(this.distanceUnit, this.timeUnit));
	}

}

redpajama_set_name: RedPajamaGithub


text:
from setuptools import setup, find_packages

setup(name='futurify',
      version='0.1',
      description='Manage __future__ imports.',
      long_description=open('README.rst').read(),
      classifiers=[
          'Development Status :: 2 - Pre-Alpha',
          'License :: OSI Approved :: MIT License',
          'Programming Language :: Python :: 2',
          'Programming Language :: Python :: 2.7',
          # FIXME Coming soon!
          #'Programming Language :: Python :: 3',
          #'Programming Language :: Python :: 3.3',
      ],
      keywords='future imports syntax static analysis lint',
      url='http://github.com/storborg/futurify',
      author='Scott Torborg',
      author_email='scott@cartlogic.com',
      install_requires=[
      ],
      license='MIT',
      packages=find_packages(),
      test_suite='nose.collector',
      tests_require=['nose'],
      zip_safe=False,
      entry_points="""\
      [console_scripts]
      futurify = futurify:main
      """)


text:
module.exports = function (grunt) {
    grunt.config(['copy', 'liveDeploy'], {
        files: [
            {expand: true, cwd: 'tmp', src: ['**'], dest: '<%= env.live.mount %>/news/special/<%= config.year %>/newsspec_<%= config.project_number %>/content'}
        ]
    });
    grunt.config(['replace', 'prepLiveDeploy'], {
        src: ['tmp/*/**.*', 'tmp/*/half_wide/**.*'],
        overwrite: true,
        replacements: [{
            from: '<%= env.local.domain %>',
            to:   '<%= env.live.domain %>'
        }, {
            from: '<%= env.local.domainStatic %>',
            to:   '<%= env.live.domainStatic %>'
        }]
    });
    grunt.loadNpmTasks('grunt-text-replace');
    grunt.loadNpmTasks('grunt-contrib-copy');
    grunt.registerTask('live', ['stage_checklist', 'checkStage', 'prepDeploy', 'replace:prepLiveDeploy', 'copy:liveDeploy', 'clean:main']);
};


text:
from __future__ import print_function, unicode_literals

from optparse import make_option

from django.core.management.base import BaseCommand
from django import db

from mezzanine.twitter.models import Query, TwitterQueryException

class Command(BaseCommand):
    """
    Polls the Twitter API for tweets associated to the queries in templates.
    """

    option_list = BaseCommand.option_list + (
        make_option("--force", default=False, action="store_true"),
    )

    def handle(self, **options):
        queries = Query.objects.all()
        if not options["force"]:
            queries = queries.filter(interested=True)
        for query in queries:
            try:
                query.run()
            except TwitterQueryException as e:
                print("Twitter query error [%s]: %s" % (query, e))
        try:
            db.close_connection()
        except:
            pass


text:
Kraken is a processing tool that allows the user to run on either official CMS data/MC samples or on locally produced Panda files. It uses a number of other packages and relies on a database to manage requests and the output files.

## Private Monte Carlo Samples

### Copy them to a convenient location

A convenient location could be the Tier-2 it could also be the Tier-3 but Tier-2 is prefered.

## Installation

* clone git://github.com/cpausmit/Kraken
* edit the ./Kraken/setup.sh file to match your specific setup
* source ./Kraken/setup.sh

## Running independent test job interactively

## Typical use for Panda file production

### Install your own code

* export KRAKEN_CMSSW=$HOME/cms/cmssw

To properly version your output/code use a three digit number starting from '000' to '999' which will be used subsequently to make sure the right code is selected and data is stored depending on the version number. So, install the code for example in $KRAKEN_CMSSW/000.

The tar ball later created for the submission will pack up your bin/ lib/ src/ python/ so you can use all of that.

### Execution Script

export KRAKEN_SCRIPT=releaseKraken.sh

This script is what condor executes. Release Kraken is fairly general and should allow you to do what you need to do. It would be a good idea to not change the script, but of course you can, and you can edit releaseKraken.sh to your likings, but be careful, damage can be done.

### Executable

export KRAKEN_EXE=slimmer

The executable that is used inside the execution script can be freely specified. Best is to place it in the bin directory in your CMSSW release area because that will be in your path automatically.

### Requesting a Sample

Instead of just submitting your sample, which you could with submitCondor.py and many parameters, it is recommended to add a request to the database. This might seem painful initially but it enables a whole slew of automation, including monitoring.

* addRequest.py --dbs local --config slimmr --version 000 --py fake --dataset pandaf=002=SinglePhoton+Run2016H-03Feb2017_ver3-v1+MINIAOD

The sample we request is not an officical CMS sample (dbs) but a local Panda sample. It derives from the official CMS sample SinglePhoton+Run2016H-03Feb2017_ver3-v1+MINIAOD and was derived using the pandaf configuration with version 002 as inidcated in the full dataset name.
The dataset properties will be stored when you request the dataset so make sure it is complete at this time. If you want to go back, you can re-declare the sample which will update the database, but be careful, the output of the same previously requested sample should be carefully removed to avoid event overlaps as several input files are combined into one output file and the definitions are likely not the same anymore. The input for the job splitting comes from the catalogs (one fileset one job).

### Submitting a job standalone

There is no need to request the sample through the database and you can go head and submit a sample production interactively. To submit your jobs running on the local Panda sample as specified above just do this:

* submitCondor.py --noCleanup --dbs=local --py=fake --config=slimmr --version=000 --dataset=pandaf=002=SinglePhoton+Run2016H-03Feb2017_ver3-v1+MINIAOD

The submission is safe as far as already submitted or completed jobs concerns. They are accounted for in the submission process and only what is not completed or not queued will be submitted.

## Status


text:
- infos = Information about the jni plugin is in keys below
- infos/author = Markus Raab <elektra@libelektra.org>
- infos/licence = BSD
- infos/provides =
- infos/needs =
- infos/placements = getstorage setstorage
- infos/status = maintained unittest configurable global memleak experimental discouraged
- infos/description = generic Java plugin

## Introduction

Allows you to write plugins in Java.

This plugin needs the JNA bindings to work.
Furthermore, it requires Java 8 or later.

While the plugin internally uses JNI (thus the name), the Java
binding for your Java plugin may use something different, e.g. JNA.
The requirements for the Java bindings are:

- needs to have the classes `elektra/Key` and `elektra/KeySet` with
  - a constructor that takes a C-Pointer as long (J)
  - a method "release" that gives up ownership (set internal pointer to NULL)

The Java plugin itself needs to have the following methods:

- constructor without arguments (i.e. default constructor)
- open with argument `elektra/KeySet` (the plugin's conf) and `elektra/Key`
- close with argument `elektra/Key`
- get with arguments `elektra/KeySet` and `elektra/Key`
- set with arguments `elektra/KeySet` and `elektra/Key`
- error with arguments `elektra/KeySet` and `elektra/Key`

## Installation

### Java Prerequisites on Debian 9

openjdk-8 and 9 do not work reliable: jvm crashes without usable backtrace.

When using non-standard paths, you have to set JAVA_HOME before invoking cmake.
(For example when you unpack Oracle Java to `/usr/local` or `/opt`.)
For example:

```sh
JAVA_HOME=/usr/local/jdk-9.0.1
```

### Java Prerequisites on Debian 8

Please install java8 as package, e.g.
[for debian](http://www.webupd8.org/2014/03/how-to-install-oracle-java-8-in-debian.html)
and then let cmake actually find jdk8:

```sh
cd /usr/lib/jvm/ && sudo rm -f default-java && sudo ln -s java-8-oracle default-java
```

and for the run-time, create the file
`/etc/ld.so.conf.d/java-8-oracle.conf` with the content (for amd64):

```
/usr/lib/jvm/default-java/jre/lib/amd64
/usr/lib/jvm/default-java/lib/amd64
/usr/lib/jvm/default-java/jre/lib/amd64/server
```

and run:

```sh
sudo ldconfig
```

### Java Prerequisites on macOS

macOS includes an old apple specific version of java, based on 1.6.
However, for the jni plugin version 1.8 of Java is required, so either the openjdk or the oracle jdk has to be installed.

Please install oracle's jdk8 via their provided installer.
After that, you have to set the JAVA_HOME environment variable to the folder where the jdk is installed, usually like

```sh
export JAVA_HOME="/Library/Java/JavaVirtualMachines/jdk1.8.0_112.jdk/Contents/Home/"
```

As macOS handles linked libraries differently, there is no ldconfig command.
Instead you can export an environment variable to tell elektra the location of the java dynamic libraries.

```sh
export DYLD_FALLBACK_LIBRARY_PATH="/Library/Java/JavaVirtualMachines/jdk1.8.0_112.jdk/Contents/Home/jre/lib:/Library/Java/JavaVirtualMachines/jdk1.8.0_112.jdk/Contents/Home/jre/lib/server/"
```

Afterwards, the jni plugin should be included in the build and compile successfully.

#### Troubleshooting

If it should still not find the correct jni version, or says the jni version is not 1.8, then it most likely still searches in the wrong directory for the jni header file.
It has been experienced that if the project has been built already without this environment variable set, the java location is cached.
As a result, it will be resolved wrong in future builds, even though the environment variable is set.
To resolve this, it should be enough to delete the CMakeCache.txt file in the build directory and reconfigure the build.

### Enabling the Plugin

Then enable the plugin using (`ALL;-EXPERIMENTAL` is default):

```sh
cmake -DPLUGINS="ALL;-EXPERIMENTAL;jni" /path/to/libelektra
```

Running

```sh
kdb-full
```

should work then (needs BUILD_FULL cmake option), if you get one of these:

```
kdb-full: error while loading shared libraries: libmawt.so: cannot open shared object file: No such file or directory
kdb-full: error while loading shared libraries: libjawt.so: cannot open shared object file: No such file or directory
```

You missed one of the ldconfig steps.

## Plugin Config

You need to pass :

- classname the classname to use as plugin, e.g. `elektra/plugin/Echo`
- classpath the classpath where to find JNA, the package elektra and
  other classes needed

Additionally, you can set:

- option allows you to pass an option to the jvm, default: `-verbose:gc,class,jni`
- ignore allows you to ignore broken options, default: `false`
- print allows you to print java exceptions for debugging purposes

E.g.

```sh
kdb plugin-info -c classname=elektra/plugin/PropertiesStorage,classpath=.:/usr/share/java/jna.jar:/usr/lib/java:/path/to/libelektra/src/bindings/jna,print= jni
kdb plugin-check -c classname=elektra/plugin/PropertiesStorage,classpath=.:/usr/share/java/jna.jar:/usr/lib/java:/path/to/libelektra/src/bindings/jna,print= jni
kdb mount -c classname=elektra/plugin/PropertiesStorage,classpath=.:/usr/share/java/jna.jar:/usr/lib/java:/path/to/src/bindings/jna,print= file.properties /jni jni classname=elektra/plugin/PropertiesStorage,classpath=.:/usr/share/java/jna.jar:/usr/lib/java:/path/to/libelektra/src/bindings/jna,print=
```

Or if `.jar` is already installed:

```sh
bin/kdb mount -c classname=elektra/plugin/PropertiesStorage,classpath=.:/usr/share/java/jna.jar:/usr/share/java/elektra.jar,print= file.properties /jni jni classname=elektra/plugin/PropertiesStorage,classpath=.:/usr/share/java/jna.jar:/usr/share/java/elektra.jar,print=
```

Additionally, the java implementation can request any other additional
configuration, read about it below in the section (specific java plugin).
If you are reading this page on GitHub, you won't see it, because the
plugins dynamically append text after the end of this page.

## Development

To know how the methods of your class are called, use:

```sh
javap -s YourClass
```

Also explained
[here](https://docs.oracle.com/javase/7/docs/technotes/guides/jni/spec/types.html#wp15773)

[JNI Functions](https://docs.oracle.com/javase/7/docs/technotes/guides/jni/spec/functions.html)
[Invocation](https://docs.oracle.com/javase/7/docs/technotes/guides/jni/spec/invocation.html)

## Issues

Argumentation for discouraged:

- You cannot use the plugin with openjdk:
  You get a linker error because of some missing private SUN symbols.
  In Debian9 it crashes with openjdk8/9.
- Only a single java plugin can be loaded
- When this plugin is enabled, valgrind detects memory problems even if
  the plugin is not mounted.


text:
jui.define("chart.grid.fullblock", [ "util.scale", "util.base" ], function(UtilScale, _) {

    /**
     * @class chart.grid.block
     * Implements Block Grid
     *
     *  { type : "block", domain : [ 'week1', 'week2', 'week3' ] }
     *
     * @extends chart.grid.core
     */
    var FullBlockGrid = function() {

        this.checkDrawRect = function(index, isLast) {

            if (isLast) {
                return false;
            }

            return true;
        }

        /**
         * @method top
         *
         * @protected
         */

        this.top = function(g) {
            this.drawTop(g, this.domain, this.points, null, -this.half_band);
            this.drawBaseLine("top", g);
        }

        /**
         * @method bottom
         *
         * @protected
         */
        this.bottom = function(g) {
            this.drawBottom(g, this.domain, this.points, null, -this.half_band);
            this.drawBaseLine("bottom", g);
        }

        /**
         * @method left
         *
         * @protected
         */
        this.left = function(g) {
            this.drawLeft(g, this.domain, this.points, null, -this.half_band);
            this.drawBaseLine("left", g);
        }

        /**
         * @method right
         *
         * @protected
         */
        this.right = function(g) {
            this.drawRight(g, this.domain, this.points, null, -this.half_band);
            this.drawBaseLine("right", g);
        }

        /**
         * @method initDomain
         * block grid 에 대한 domain 설정
         * @private
         */
        this.initDomain = function() {

            var domain = [];

            if (_.typeCheck("string", this.grid.domain)) {
                var field = this.grid.domain;
                var data = this.data();

                if (this.grid.reverse) {
                    var start = data.length - 1,
                        end = 0,
                        step = -1;
                } else {
                    var start = 0,
                        end = data.length - 1,
                        step = 1;
                }

                for (var i = start; ((this.grid.reverse) ? i >= end : i <=end); i += step) {
                    domain.push(data[i][field]);
                }

                //grid.domain = domain;
            } else if (_.typeCheck("function", this.grid.domain)) {	// block 은 배열을 통째로 리턴함
                domain = this.grid.domain.call(this.chart);
            } else {
                domain = this.grid.domain;
            }

            if (this.grid.reverse) {
                domain.reverse();
            }

            return domain;

        }

        /**
         * @method drawBefore
         *
         * @protected
         */
        this.drawBefore = function() {
            var domain = this.initDomain();

            var obj = this.getGridSize();

            // scale 설정
            this.scale = UtilScale.ordinal().domain(domain);
            var range = [obj.start, obj.end];

            this.scale.rangeBands(range);

            this.start = obj.start;
            this.size = obj.size;
            this.end = obj.end;
            this.points = this.scale.range();
            this.domain = this.scale.domain();

            this.band = this.scale.rangeBand();
            this.half_band = 0 ;
            this.bar = 6;
            this.reverse = this.grid.reverse;
        }

        /**
         * @method draw
         *
         * @protected
         * @return {Mixed}
         */
        this.draw = function() {
            return this.drawGrid("block");
        }
    }

    FullBlockGrid.setup = function() {
        return {
            /** @cfg {String/Array/Function} [domain=null] Sets the value displayed on an axis.*/
            domain: null,
            /** @cfg {Boolean} [reverse=false] Reverses the value on domain values*/
            reverse: false,
            /** @cfg {Number} [max=10] Sets the maximum value of a grid. */
            max: 10
        };
    }

    return FullBlockGrid;
}, "chart.grid.core");


text:
using Akka.Actor;
using Game.ActorModel.Actors;
using System;

namespace Game.Web.Models
{
    public static class GameActorSystem
    {
        private static ActorSystem ActorSystem;

        public static void Create()
        {
            ActorSystem = ActorSystem.Create("GameSystem");

            ActorReferences.GameController = ActorSystem.ActorOf<GameControllerActor>();
        }

        public static void ShutDown()
        {
            ActorSystem.Shutdown();

            ActorSystem.AwaitTermination(TimeSpan.FromSeconds(1));
        }

        public static class ActorReferences
        {
            public static IActorRef GameController { get; set; }
        }
    }
}


text:
<?php
/////////////////////////// 设置文档标题、作者、email
$title = '《How to Start a Startup》YC';
$author = '犀利哥';
$email = '23771066@qq.com';

require __DIR__.'/../_header.php';

/////////////////////////// 文档内容开始
$md = <<<SSS
# 课程地址
-------------------------
https://startupclass.co/
http://open.163.com/special/opencourse/startup.html

# 课程列表
-------------------------
=blue
1. Why you should start a startup - Dustin Moskovitz

-------------------------
The Best Reason: `You Can't Not Do It`
- `Passion`: You need to do it
You'll need passion to endure The Struggle
You'll need passion to effectively recruit
- `Aptitude`: The world needs you to do it
    - The world needs it
Otherwise do something that the world needs
    - The world needs you
It's bad for the world if you just outcompete a team with more aptitude
The world needs you somewhere - find where

>创业只有一个原因:你不得不去创业,因为命运选择了你
你拥有要去做这件事的难以抑制的激情+这个世界需要这个东西+你拥有做这件事的最好的天赋

![Facebook](https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=3918435651,2140737301&fm=27&gp=0.jpg)
![Asana](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511966428&di=214b4fc5bc1624a3e6d6015c8cc93780&imgtype=jpg&er=1&src=http%3A%2F%2Fpic2.pedaily.cn%2Fnewseed%2Fproject%2F201603%2F20160331144011800.jpg)

=blue
2. Ideas, Products, Teams and Execution - Sam Altman

-------------------------
=blue Ideas
The `Idea` comes first
The company should feel like an important `mission`

=blue Products
Build something users `love`
Talk to users
Show it to users -> `User feedback` -> Product Decisions loop
- What do they like?
- What would they pay for?
- What would make them recommend it?

Metrics: Focus on `growth`
- Total registrations
- Active users
- Activity Levels
- Cohort Retention
- Revenue
- Net Promoter Score

=blue Teams
Cofounders should be `Relentlessly Resourceful`
You are looking for co-founders that need to be unflappable, tough, know what to do in every situation, act quickly, decisive, creative, ready for anything
Know your cofounders
Try not to hire
Get the best people
Mediocre engineers do not build great companies
- Are they smart?
- Do they get things done?
- Do I want to spend a lot of time around them?
- Good communication skills
- Manically determined
- Pass the animal test
- Would feel comfortable reporting to them

You've hired the best - now keep them around!
Fire fast

=blue Execution
The CEO has five jobs
- Set the vision
- Raise money
- Evangelize
- Hire and manage
- Make sure the entire company executes

Focus
- What are you spending time and money on? opera
- What are the two or three most important things?
- Say no. A lot.
- Set overarching goals. Repeat them
- Communicate
- Maintain growth and momentum
- Work together in person

Intensity
- Relentless operating rhythm
- Obsession with Execution Quality
- Bias towards action
- Quick
- Do Whatever it takes
- Show up
- Don't give up
- Be courageous

Always keep momentum
Always keep growing
Set an operation rhythm
- Shipping product
- Launching new features
- Reviewing/reporting metrics and milestones

The competitor to be feared is one who never bothers about you at all, but goes on making his own business better all the time.
Don't spend more money than you have

>尽量找熟知的合伙人
从同行里找到优秀的合伙人
最好有两三个合伙人
员工越多不一定越好
创业初期尽量少招人,减少成本
为自己的公司找最优秀的人才
最好找与你一样相信公司,并符合你期待的人
要熟悉每个你雇佣的人
要以期权的形式分配股份
股份的分配最好在公司建立之初就和合伙人协商好
在执行方面,首先要清楚自己要做什么,其次就是是否能完成
如果你知道自己要做什么,剩下的就是专注和保持增长势头
要在许多事情中选出自己觉得最重要的做,而不是漫无目的
要让整个公司都清楚目标
保持增长势头可以鼓舞士气,保持信心,一切问题都迎刃而解
无视你的竞争者,不要让他们破坏你的增长势头

![YC](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511371972652&di=cc0b61f90f318ae83c70ee9649a62fbd&imgtype=0&src=http%3A%2F%2Fa4.att.hudong.com%2F60%2F45%2F01300000354882123876458091228.gif)

=blue
3. Counterintuitive Parts of Startups, and How to Have Ideas - Paul Graham

-------------------------

>创业中反直觉的几条原则
不能一味跟着直觉走
成功创业需要的并不是创业知识专家
找诀窍在创业中是行不通的
创业比想象中的还要艰辛
创业前途未卜
获得创意的方法就是不去刻意想创意

![YC](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511371972652&di=cc0b61f90f318ae83c70ee9649a62fbd&imgtype=0&src=http%3A%2F%2Fa4.att.hudong.com%2F60%2F45%2F01300000354882123876458091228.gif)

=blue
4. Building Product, Talking to Users, and Growing - Adora Cheung

-------------------------
>选择行业,并对该行业有所了解
简单定义企业特点,明确客户群体,实地营销
关注客户价值
建立良好的宣传和推荐机制
三种增长模式 - 高粘度增长、病毒式增长、付费增长
要坚持创意同时也要在适当的时机学会放弃,找到适合自己的创业路子

在3年里pivot了12次,终于获得$37M融资把Homejoy做起来
师兄的今日头条也是一个积极pivot并走向成功的例子
另一个案例是一个同学做微商,一直没有增长,半死不活的状态坚持了很多年,其实他早该pivot
现实中大多数创业团队都需要转型,而且关键在于转型的速度和质量

=warn 可惜的是,作为共享经济、O2O的鼻祖企业,Homejoy于2015年倒闭。

![HomeJoy](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511521689764&di=17f13ba129bd6f302405205f37dba63a&imgtype=0&src=http%3A%2F%2Fimage.sowm.cn%2Fm2EZRv.gif)

=blue
5. Business Strategy and Monopoly Theory - Peter Thiel

-------------------------
`Competition is for losers`
- capturing value
    - X*Y%
- lies people tell
- how to build a monopoly
    Characteristics of Monopoly
    - proprietary technology
    - network effects
    - economies of scale
    - branding
- last mover advantage
- history of innovation
    Success cases
    - Vertically integrated complex monopolies
    Ford, Standard Oil, Tesla, SpaceX
    - Software
    economies of scale, low marginal cost, high adoption rate
- psychology of competition

>衡量一个公司的价值的方法,创造X美元的价值,并把其中的Y%把握在自己手中,X和Y是独立的
形成垄断的重要切入点是进入小的市场,并迅速占领这个市场,因为大的市场竞争非常激烈,所有的价值都在竞争中消耗掉了
虽然第一个吃螃蟹的人很勇敢,但最重要的是要做笑到最后的人,因此必须不断创新,保持竞争力
跨界融合式创新可能更容易成功,如Tesla
软件很容易成为爆点,因为边际成本为0,如Google、Facebook
不要拘泥于完全竞争的弹丸之地,转角你可能会发现巨大的机会
精益创业无用,伟大的公司都是做出巨大的改变以和其他人区别开来

=info PT是那种长远思考、一眼看到底、预见未来的人,在PT眼里精益创业根本就是浪费时间瞎碰运气

![PayPal](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511522627428&di=a6d2fcaabac47752ed91723a254d5f3c&imgtype=0&src=http%3A%2F%2Fstatic.leiphone.com%2Fuploads%2Fnew%2Farticle%2F740_740%2F201606%2F5754f6099ec3b.png)
![Palantir](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511522415537&di=ab252674984f224f541c2bf317d38482&imgtype=0&src=http%3A%2F%2Fwww.yuntoutiao.com%2Fwp-content%2Fuploads%2F2016%2F02%2Fpalantir-logo.png)

=blue
6. Growth - Alex Schultz

-------------------------
>对于网站,用户留存率是最重要的,而这则取决于产品的好坏,因此先要做好产品
`选对增长目标,制造激动时刻`
Airbnb的激动时刻就是你发现了一个很酷的房间,在你推门进去的那一刻
比如Facebook的激动时刻就是看到你的朋友也在使用它
Facebook的第一个增长目标就是专注于让用户14天内找到10个朋友,使用户体验激动时刻
Facebook的第二个增长目标是国际化
病毒式营销:Payload、Frequency、CR

![Facebook](https://ss1.bdstatic.com/70cFvXSh_Q1YnxGkpoWK1HF6hhy/it/u=3918435651,2140737301&fm=27&gp=0.jpg)

=blue
7. How to Build Products Users Love I - Kevin Hale

-------------------------
>给用户留下良好的第一印象
重视客服的影响力

![Wufoo](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511522900458&di=2f1685cf41fb4110ef82c4bfd8b77e23&imgtype=0&src=http%3A%2F%2Fwww.kuqin.com%2Fupimg%2Fallimg%2F110913%2F22152051F-1.jpg)

=blue
8. Doing Things That Don't Scale, PR, and How to Get Started - Walker Williams

-------------------------
>Test your hypothesis
Launch fast
Do things that don't scale
Finding your first users
Turning those users into champions
Finding product/market fit
Use press

![DOORDASH](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511523269070&di=dfc3bd7a87fd27ca3320d5a7251326cc&imgtype=0&src=http%3A%2F%2Fupload.uschinapress.com%2F2017%2F0324%2F1490395605153.jpg)
![teespring](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511599304678&di=d2c6b04f6b17dc347a96aeca51f7223f&imgtype=0&src=http%3A%2F%2Fimglf0.ph.126.net%2FXue3cOFx_z3_mZdPjUZx-g%3D%3D%2F6631566943978885527.png)
![twitch](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511523272362&di=0e7ce9b5ab8d1ed51f8f22ef69a85cdf&imgtype=0&src=http%3A%2F%2Fimg.android.d.cn%2Fandroid%2Fnew%2Fgame_image%2F80%2F16180%2Fbanner.png)

=blue
9. How to Raise Money - Marc Andreessen

-------------------------
>Is this person a leader?
Is this person rightful, focused, and obsessed by the product?
Say in one compelling sentence so that the investor immediately can picture the product in their own mind
Key to success is be so good they can't ignore you

=blue Onion theory of risk:
- make a list of risks
- running a startup & raising money is a process of peeling away layers of risk
- raise seed money to peel away the first two or three risks(founding team, product)
- raise A round to peel away the next level of risks(product, recruiting, customer)
- peeling away your risk by achieving milestones, both making progress in business and justifying raising more capital
- I raised a seed round, I achieved these milestones, I eliminated these risks, I raised the A round, I achieved these milestones, I eliminated these risks, now I am raising a B round, here are my milestones, here are my risks, and by the time I go to raise a C round, here is the state I will be in, and calibrate the amound of money you raise and spend to the risks that you are pulling out of the business

=blue What Ron and SV Angel Look for in a Company
=blue What We Look For
- Great team is #1 - "chemistry with Founders"
- Solid idea or product is important, prerequisite
- Company in growth sector
- Solving practical and real problem
- Strong network effects and first-mover advantage
- Metrics matter - know signals of consumer adoption
- Early traction and working beta product
- Good elevator pitch - keep it simple
- Decisiveness - often tested in building the team
- Exec summary important as door opener
- IP does Matter
- Don't over-negotiate or dwell on terms - get back to building a big company!
- Hire ahead of needs and do backdoor references
- Understand success rate
- Distribution and business development always important - SALES!

=blue Founder Personal Characteristics
- Decisiveness - often tested in building the team
- Do not procrastinate
- Be proactive
- Clear vision - entire team understands direction and mission
- Team and team builder as CEO
- Passion
- Flexibility on idea and morph constantly
- Good listeners - strong willed but flexible
- Reliability and responsiveness
- Move fast, sweat logistics - devil in details
- Execution is everything - make mistakes but learn from them
- Trust your gut, make decisions
- Reliability and Responsiveness
- Over-communicate with everyone - the team, investors, customers, etc.
- Hire aggressively ahead of needs
- Lead by example - 24/7, no distractions

=blue How To Pick Your Investors
- Rolodex vs time vs Pedigree and Track Record
- Helping on next financing round
- How many repeat entrepreneurs choose again
- Backdoor references
- Value add
- Business advice via pattern recognition
- Experience, mentoring
- Network, syndicate
- Responsiveness

![SV Angel](https://svangel.com/i/sv-angel-logo.png)

=blue
10. Company Culture and Building a Team I - Alfred Lin

-------------------------
> Culture is the thing that's gonna be very very important for you to be able to scale the business as well as your team
Company culture is everyday core values and actions of each member of the team in pursuit of our company mission
Your beliefs become your thoughts. Your thoughts become your words. Your words become your actions. Your actions become your habits. Your habits become your values. Your values become your destiny.
Fast=First Principles+Aignment+Stability+Trust+Exclusion+Retention

=blue Core value worksheet:
- As the leader, what personal values are most important to you?
- What are the most important values for business success?
- What values will you look for in employees?
- What could never be tolerated?(consider the opposite as values)
- Remember to incorporate your mission into your core values

=blue Elements of high performing teams:
- Trust
- Conflict
- Commitment
- Accountability
- Results

=blue Best Practices for culture:
- Incorporate your mission to your values
- Performance = think harder, deeper, longer about values
- Interview for culture fit
- Evaluate performance on culture as well
- Make it a daily habit

![Sequoia](https://ss2.bdstatic.com/70cFvnSh_Q1YnxGkpoWK1HF6hhy/it/u=1013209256,3897995824&fm=27&gp=0.jpg)

=blue
11. Company Culture and Building a Team II - Patrick Collison

-------------------------
使命->文化->招聘和打造足够优秀的、符合文化的团队
想天使投资人一样寻找自己的雇员:
- `有强烈好奇心`
- `自学能力强`
- `不断创造新东西`
- `属于Be-Better类型`
- `有独立思考能力`
- `方法论明晰`
- `价值观坚定`

![stripe](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511523996685&di=31ebbbd53ac39b16b5eeb4b8efe01e2f&imgtype=0&src=http%3A%2F%2Fwww.ibtimes.com.cn%2Fimg%2Fchinese%2Fdata%2Fimages%2Ffull%2F2014%2F12%2F25%2F44801.png)

=blue
12. Sales and Marketing - Aaron Levie

-------------------------
=blue Listen to customers
But don't always build exactly what they want.
Build what they need.

=blue Modularize, don't customize
Every customer will want something a little bit different.
Don't make the product suffer for this.
Open APIs as a way of delivering vertical or custom experiences.

=blue Focus on the user
Keep "consumer" DNA at the core of your enterprise product.
This will always pay dividends.

=blue Your product should sell itself
Sales should be used to navigate customers and close deals, not be a substitute for great product.

![box](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511524481421&di=9de367053cbbdfe11d57e0f97c3866b8&imgtype=0&src=http%3A%2F%2Fwww.yuntoutiao.com%2Fwp-content%2Fuploads%2F2014%2F10%2FBOX.jpg)

=blue
13. How To Be A Great Founder - Reid Hoffman

-------------------------
=blue How do I be a great founder
- Founding Team
- Location
- Delegation
- Focus
- Vision
- Evaluation
- Confidence
- Risk
- Data
- Time horizon
- Persistence
- idea
- marketing
- scaling
- equity
- financing
- legal
- culture
- recruiting
- competition
- management
- design
- growth hacking
- product
- operations
- pivoting
- execution
- communication
- business strategy
- focus groups

=blue Team
Have two or three people on a team rather than a solar founder is much better
There' this very broad set of skills. There's this whole set of questions about how you adapt your company in order to be successful.
If you have two or three founders, you have different skills, you can compensate for each other's weaknesses
You can in the diversity of problems that you encounter as a founder that you can actually attack them

=blue Location
When you're founding a company, go to where it's successful to this
`Entrepreneurship is jumping off a cliff and assembling an airplane on the way down`

=blue Contrarian
What's the way that what do I know that other people don't know?
Go talk to every smart person who will talk to you and give you feedback, think about how is it that smart people disagree with me? AND there's something that I know that they don't know that actually in fact will play out to be true.

![Linkedin](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511524592281&di=7677e41714544865de56f78b09e5df0a&imgtype=jpg&src=http%3A%2F%2Fimg0.imgtn.bdimg.com%2Fit%2Fu%3D687368685%2C1755241334%26fm%3D214%26gp%3D0.jpg)

=blue
14. How to Operate - Keith Rabois

-------------------------
做一个公司比做一个产品难多了,根本的原因在于人是非理性的
打造一个公司就像是要把所有这些不理性的人,放在同一个屋子里然后和他们一天至少生活12个小时
A manager's output = The output of his organization + The output of the neighboring organizations under his influence
`打造一个公司就像打造一个引擎`
`像编辑一样运营一个公司 - Editing`
- Simplify(精简,提炼 - 问题)
- Clarify(阐明,精准 - 目标)
- Allocate Resources(轻重缓急)
- Ensure Consistent Voice(步调一致)
- Delegate(熟练则放权,监控和设定目标;不熟练则详细监控,控制进度)
Task-Relevant Maturity:
Low - Highly structured: what, when, how
High - Monitor and set objectives

![Square](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511524758409&di=5c9f50dcd04801807a6b643170211918&imgtype=0&src=http%3A%2F%2Fa.36krcnd.com%2Fphoto%2F2014%2Ff2fb057b70db0fb03181b1c867ac55a6.png)

=blue
15. How to Manage - B Horowitz

-------------------------
When making a critical decision, you must understand how it will be interpreted from each person's point of view and its impact on the union of the individual views. i.e. culture
- Do you demote or fire?
- An excellent employee asks you for a raise

=blue It's not your perspective or the perspective of the person that you are talking to at the moment that matters.
=blue You must consider the people who are not in the room.
=blue They are the company. They are the culture.

![a16z](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511594533749&di=fc07175936557a515af4d59209b2e725&imgtype=0&src=http%3A%2F%2Fimg9.91huo.cn%2Fvr%2Ffolder21%2Ffolder651%2F5626b76e03dcd0443b950646_investor-a16z-dark-solo.png)

=blue
16. How to Run a User Interview - Emmett Shear

-------------------------
>`以用户反馈作为产品开发的驱动力,做用户真正需要的产品`
用户调查和访问,需要迂回和旁敲侧击,深入提问,并透过表象看透实质

"If you could put a thousand songs in your pocket and take them anywhere," that's cool.
Not, "Do you want a digital portable music player?"

![twitch](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511523272362&di=0e7ce9b5ab8d1ed51f8f22ef69a85cdf&imgtype=0&src=http%3A%2F%2Fimg.android.d.cn%2Fandroid%2Fnew%2Fgame_image%2F80%2F16180%2Fbanner.png)

=blue
17. How to Build Products Users Love II - Hosain Rahman

-------------------------
What our process feels like?
- Exploration - Unbridled imagination
- Early validation - Proving your thesis like a Ph.D.
- Concept - Big, human-centric concepts
- Planning - Emergence of a product
- Development - Bringing it to life
- Continued innovation - Feeling the fire

`产品需要解决痛点,而不是挠痒痒`
You can't live without it
![jawbone](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511602132704&di=6cbc6ec004684bc2acec3dacc54459c6&imgtype=0&src=http%3A%2F%2Fd3osil7svxrrgt.cloudfront.net%2Fstatic%2Fwww%2Flogos%2Fjawbone%2Fjawbone-logo-display.png)

=blue
18. Mechanics--Legal, Finance, HR, etc. - Kirsty Nathoo

-------------------------
[有限责任公司和股份有限公司的区别](https://www.zhihu.com/question/21921556)
[什么是期权激励](https://www.zhihu.com/question/21818075)
[什么是VIE结构](https://www.zhihu.com/question/21217305)

如何正确的开除一个员工?
- 快,马上
- 直说,别绕弯,别道歉,少废话;最好有第三方在场
- 马上支付应该支付的费用
- 切断一切数字系统的访问权限
- 马上买回所有已经落实的期权

![YC](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511371972652&di=cc0b61f90f318ae83c70ee9649a62fbd&imgtype=0&src=http%3A%2F%2Fa4.att.hudong.com%2F60%2F45%2F01300000354882123876458091228.gif)

=blue
19. Sales and Marketing, How to Pitch, and Investor Meeting Roleplaying - Tyler Bosmeny

-------------------------
做好销售的两大法宝:
- 对自己的产品充满热情
- 对所从事的行业非常熟悉

顶级的销售在电话中,自己说话时间占30%,客户说话时间占70%
不要免费试用,而是30天内退货

They're doing everything they can to find out what this person needs and hopefully understand their problem even better than they do. That's what really great sales is.

If in one sentence you cannot tell your mom what you do, then rework the sentence

=blue 30 second pitch
- What does your company do?
- How big is the market?
- How much traction do you have?

=blue 2 minute pitch
- Clear 30 second pitch
- `Unique insight(眼前一亮,打动投资人)`
- How you make money
- Team
- The Big Ask

=blue During the meeting
- Make sure the listener understands what you're working on.
- Know your numbers!
- For market size ideally build bottom up analysis
- You should understand something that is counter intuitive
- Your team should be uniquely suited for this business
- Drive the conversation to a conclusion

=blue After the meeting
- Follow up(anything by a check is a "No")
- Work on creating deal heat(supply/demond)
- Do diligence on the investors
- Know when to stop(addicted to fundraising)
- Build your company!(fundraising is not the goal)

![Clever](https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=1418065272,63818145&fm=27&gp=0.jpg)
![YC](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511371972652&di=cc0b61f90f318ae83c70ee9649a62fbd&imgtype=0&src=http%3A%2F%2Fa4.att.hudong.com%2F60%2F45%2F01300000354882123876458091228.gif)

=blue
20. Closing Thoughts and Later-Stage Advice - Sam Altman

-------------------------
Building a great product -> Building a great company

Codify how you do things
Codify why you do things(cultural values)

Long-term thinking is rare
迈出这一步之后,一切都将不同,且再也不可能回头了,回头不是岸

![YC](https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1511371972652&di=cc0b61f90f318ae83c70ee9649a62fbd&imgtype=0&src=http%3A%2F%2Fa4.att.hudong.com%2F60%2F45%2F01300000354882123876458091228.gif)

2017.11.25

SSS;
/////////////////////////// 文档内容结束

echo $Parsedown->text($md);

require __DIR__.'/../_footer.php';
?>


text:
// -----------------------------------------------------------------------
//  <copyright file="TestExceptionType.cs" company="Phoenix Game Studios, LLC">
//      Copyright (c) 2017 Phoenix Game Studios, LLC. All rights reserved.
//      Licensed under the MIT License.
//      See https://github.com/PhoenixGameStudios/DangrLib/blob/master/LICENSE for full license information.
//  </copyright>
// -----------------------------------------------------------------------

namespace Dangr.Diagnostics
{
    public enum TestExceptionType
    {
        ValidationPassed,
        ValidationFailed,
        NullCheckFailed,
        BoundsCheckFailed,
        NotDisposedCheckFailed,
        NullReferenceException,
        IndexOutOfBoundsException
    }
}


text:
set -e

source hadoop_helpers.sh

if [[ $(hostname -s) == ${MASTER_HOSTNAME} ]]; then
  COMPONENTS=${MASTER_COMPONENTS}
else
  COMPONENTS=${DATANODE_COMPONENTS}
fi

# Component ordering is sensitive. hive-metastore must come before hive-server2
# and hdfs must be up before oozie.
for COMPONENT in ${COMPONENTS}; do
  if [[ -x /etc/init.d/${COMPONENT} ]]; then
    # Initialize HDFS
    if [[ ${COMPONENT} == 'hadoop-hdfs-namenode' ]]; then
      service hadoop-hdfs-namenode stop
      # Do not refomat if already formatted.
      yes n | service hadoop-hdfs-namenode init
      service hadoop-hdfs-namenode start

      # Setup /tmp and /user directories.
      if [[ "${DEFAULT_FS}" == 'hdfs' ]]; then
        initialize_hdfs_dirs
      fi
    # Initialize Oozie. Requires Namenode to be up.
    elif [[ ${COMPONENT} == 'oozie' ]]; then
      # Requires HDFS to be up and running.
      # Might be CDH specific.
      oozie-setup sharelib create -fs ${NAMENODE_URI} \
          -locallib /usr/lib/oozie/oozie-sharelib-yarn*
      service oozie restart
    else
      service ${COMPONENT} restart
    fi
  fi
done