#include <bits/stdc++.h>
using namespace std;
const long long int N = 1e6 + 10, MOD = 1e9 + 7, INF = 1e18;
const long double PI = acos(-1);
int n, q, pos[2 * N], in[N], f[N], cnt[8 * N], m;
vector<int> all;
void Add(int id, int val, int posi, int b = 0, int e = m, int ind = 1) {
  if (b + 1 == e) {
    pos[b] = posi;
    cnt[ind] += val;
    return;
  }
  int mid = (b + e) / 2;
  if (id < mid) Add(id, val, posi, b, mid, ind * 2);
  if (mid <= id) Add(id, val, posi, mid, e, ind * 2 + 1);
  cnt[ind] = cnt[ind * 2] + cnt[ind * 2 + 1];
  return;
}
int Get(int y, int b = 0, int e = m, int ind = 1) {
  if (b + 1 == e) {
    return b;
  }
  int mid = (b + e) / 2;
  if (y <= cnt[ind * 2]) return Get(y, b, mid, ind * 2);
  return Get(y - cnt[ind * 2], mid, e, ind * 2 + 1);
}
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  cin >> n >> q;
  m = n + q;
  for (int i = 0; i < n; i++) {
    pos[q + i] = i + 1;
    Add(i + q, 1, i + 1);
  }
  bool bad = 0;
  while (q--) {
    int x, y;
    cin >> x >> y;
    int xD = Get(y);
    int id = pos[xD];
    bad |= (f[x] && f[x] != id);
    bad |= (in[id] && in[id] != x);
    f[x] = id, in[id] = x;
    Add(xD, -1, 0);
    Add(q, 1, id);
  }
  if (bad) return cout << "-1\n", 0;
  int xD = 1;
  for (int i = 1; i <= n; i++) {
    if (in[i]) {
      cout << in[i] << ' ';
      continue;
    }
    while (f[xD]) xD++;
    cout << xD++ << ' ';
  }
  cout << '\n';
  return 0;
}
