Skip to content

Instantly share code, notes, and snippets.

context "create order" do
current_api_user = Spree.user_class.new(:email => "spree@example.com")
#current_api_user.email =
current_api_user.generate_spree_api_key!
#current_api_user.save
puts "User: #{current_api_user.inspect}"
it "can create an order" do
gem install spree_cmd
rails new _3.2.13_ my_store
cd my_store
spree_cmd . -A
Process fails with gem deps issues during bundle install "."
Modify Gemfile,
change gem "spree" to
@mribbons
mribbons / MainActivity.java
Created February 11, 2016 01:00
RS30_ReaderSample MainActivity.Java dated 30/11/2015
package com.example.readersample;
import com.cipherlab.barcode.*;
import com.cipherlab.barcode.decoder.*;
import com.cipherlab.barcode.decoderparams.*;
import com.cipherlab.barcodebase.*;
import android.app.Activity;
import android.content.BroadcastReceiver;
import android.content.Context;
@mribbons
mribbons / plugin.xml
Created March 7, 2016 11:00
rs30 test plugin
<?xml version='1.0' encoding='utf-8'?>
<!--
This file is part of Apache Cordova Barcode Scanner Plugin for Cipherlab RS30,
which shall be referred to as "the Software"
The Software is authored by Michael Ribbons who shall be referred to as "the Author".
The MDR License (MDR)
Copyright (c) 2015 Michael Ribbons
Use of the Software is granted on a case by case basis.
@mribbons
mribbons / Makefile(yolo)
Created April 17, 2018 22:01
Makefile and package config file file darknet/yolo
GPU=1
CUDNN=0
OPENCV=1
OPENMP=0
DEBUG=0
#ARCH= -gencode arch=compute_30,code=sm_30 \
-gencode arch=compute_35,code=sm_35 \
-gencode arch=compute_50,code=[sm_50,compute_50] \
-gencode arch=compute_52,code=[sm_52,compute_52]
@mribbons
mribbons / Crafting_RecipeUIHelper.lua
Created July 15, 2021 04:09
OnPressCraftButton function
function OnPressCraftButton(button)
if not LOCAL_PLAYER.clientUserData.currentlyCrafting and SpamPrevent(itemRecipe.craftTime) and craftButton == button then
CraftProgress.progress = 0
craftingCount = 0
currentHealth = LOCAL_PLAYER.hitPoints
craftingTimer = itemRecipe.craftTime or 1
-- Send a crafting event to the server which checks the player's inventory for
ingredientsPanel.visibility = Visibility.FORCE_OFF
CraftProgress.visibility = Visibility.FORCE_ON
LOCAL_PLAYER.clientUserData.currentlyCrafting = true
@mribbons
mribbons / tsconfig.json
Created June 22, 2022 04:59
shared yarn workspace package with tst-reflect issues
{
"include": ["src"],
"references": [],
"extends": "../../tsconfig.build.json",
"compilerOptions": {
"composite": true,
"incremental": true,
"rootDir": "./src",
"outDir": "./dist",
"plugins": [{ "transform": "tst-reflect-transformer" }],
@mribbons
mribbons / ini
Created December 17, 2022 10:32
android socket.ini
# Build Settings
input = "src"
build = "node build.js"
output = "dist"
executable = "SSCAndroid"
# Package Metadata
version = "0.0.1"
revision = "1"
@mribbons
mribbons / ini
Created December 17, 2022 10:40
socket.ini (desktop, mainly mac)
;
; Default configuration file for ssc v0.1.0 (111f9f7).
;
; The shell command to execute when building an application. This is the most
; important command in this file. This will do all the heavy lifting and should
; handle 99.9% of your use cases for moving files into place or tweaking
; platform-specific artifacts.
build = "node build.js"
@mribbons
mribbons / start_verdaccio.bat
Last active March 5, 2023 21:15
verdaccio private npm / win32
@REM Usage:
@REM cd c:\socketsupply\create-socket-app && ..\start_verdaccio && cd ..\socket && sh bin\publish-npm-modules.sh
@REM Requires mingw sh (= git sh) in PATH
@REM requires npm i -g npm-cli-login
@REM Make sure URL doesn't have a trailing slash
@ Use this environment variable in another terminal where you want to use this server instead of npmjs
set NPM_CONFIG_REGISTRY=http://localhost:4873
@REM Clear package storage so we can push the same version again
rm -rf %APPDATA%\verdaccio\storage